What will be the output of the following Python code? (Please ignore the erratic indentation)
text = "Hello World"
print(text.lower())
CPT C04 Programming (math, random, string, logical)
Quiz
•
Information Technology (IT)
•
10th Grade
•
Medium
woai chemhepython
Used 1+ times
FREE Resource
32 questions
Show all answers
1.
FILL IN THE BLANK QUESTION
1 min • 1 pt
What will be the output of the following Python code? (Please ignore the erratic indentation)
text = "Hello World"
print(text.lower())
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What does the split() method do in Python?
Joins a list of strings into a single string
Splits a string into a list based on a delimiter
Finds the index of a substring
Replaces a substring with another string
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following statements correctly removes whitespace from both ends of a string?
text.strip()
text.trim()
text.remove_spaces()
text.split()
4.
FILL IN THE BLANK QUESTION
1 min • 1 pt
What will be the output of the following Python code? (Please ignore the erratic indentation)
word = "Python"
print(word[::-1])
5.
FILL IN THE BLANK QUESTION
1 min • 1 pt
What will be the output of the following Python code? (Please ignore the erratic indentation)
s = "apple,banana,cherry"
print(s.split(","))
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following Python expressions will correctly extract "Python" from the string
text = "Learn Python Programming"?
test[6:12]
text.split()[1]
text.find("Python")
text[6:11]
7.
FILL IN THE BLANK QUESTION
1 min • 1 pt
What will be the output of the following code? (Please ignore the erratic indentation)
s = "O-Level Computing"
print(s[-9:])
34 questions
G10 - Ôn tập cuối kì mùa Đông
Quiz
•
10th Grade
35 questions
Python Programmieren 1.0
Quiz
•
10th Grade
29 questions
Teste de Avaliação em Python
Quiz
•
10th Grade
30 questions
Kiến thức cơ bản về Python lop 10
Quiz
•
10th Grade
30 questions
Test3
Quiz
•
9th - 12th Grade
37 questions
8 класс цикл
Quiz
•
8th Grade - University
28 questions
Review Python_G8
Quiz
•
8th Grade - University
30 questions
Y9 Python Review
Quiz
•
9th Grade - University
15 questions
Character Analysis
Quiz
•
4th Grade
17 questions
Chapter 12 - Doing the Right Thing
Quiz
•
9th - 12th Grade
10 questions
American Flag
Quiz
•
1st - 2nd Grade
20 questions
Reading Comprehension
Quiz
•
5th Grade
30 questions
Linear Inequalities
Quiz
•
9th - 12th Grade
20 questions
Types of Credit
Quiz
•
9th - 12th Grade
18 questions
Full S.T.E.A.M. Ahead Summer Academy Pre-Test 24-25
Quiz
•
5th Grade
14 questions
Misplaced and Dangling Modifiers
Quiz
•
6th - 8th Grade
17 questions
Chapter 12 - Doing the Right Thing
Quiz
•
9th - 12th Grade
20 questions
Types of Credit
Quiz
•
9th - 12th Grade
30 questions
Linear Inequalities
Quiz
•
9th - 12th Grade
20 questions
Taxes
Quiz
•
9th - 12th Grade
17 questions
Parts of Speech
Quiz
•
7th - 12th Grade
20 questions
Chapter 3 - Making a Good Impression
Quiz
•
9th - 12th Grade
20 questions
Inequalities Graphing
Quiz
•
9th - 12th Grade
10 questions
Identifying equations
Quiz
•
KG - University