Introducing Python Strings
Quiz
•
Computers
•
11th Grade
•
Practice Problem
•
Hard
Harmeet Kaur
FREE Resource
Enhance your content in a minute
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
10 sec • 1 pt
What is the index of the first character in a string?
5
-1
1
0
2.
MULTIPLE CHOICE QUESTION
10 sec • 1 pt
How do you access the last character of a string named 'text'?
text[-1]
text[length]
text.last()
text.charAt(-1)
3.
MULTIPLE CHOICE QUESTION
10 sec • 1 pt
Is a string in Python mutable or immutable?
immutable
modifiable
variable
mutable
4.
MULTIPLE CHOICE QUESTION
10 sec • 1 pt
What will be the output of 'hello'[1:4]?
ell
hel
lo
hello
5.
MULTIPLE CHOICE QUESTION
10 sec • 1 pt
How can you find the length of a string in Python?
len(your_string)
length(your_string)
your_string.length()
string.length(your_string)
6.
MULTIPLE CHOICE QUESTION
10 sec • 1 pt
What does the method 'str.upper()' do to a string?
It removes all whitespace from the string.
It converts all characters in the string to lowercase.
It converts all characters in the string to uppercase.
It reverses the order of characters in the string.
7.
MULTIPLE CHOICE QUESTION
10 sec • 1 pt
If 's = "Python"', what is 's[0:2]'?
Pyth
on
Py
Python
Create a free account and access millions of resources
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Similar Resources on Wayground
10 questions
INTRODUCCION A LA PROGRAMACION
Quiz
•
6th Grade - University
10 questions
(LS) CPA CPF5 Storage Device
Quiz
•
6th - 12th Grade
15 questions
PTS Algoritma dan Pemrograman
Quiz
•
9th - 12th Grade
15 questions
9-klass informatika 2-sherek monitoring test sorawları
Quiz
•
9th - 12th Grade
15 questions
Latihan_106
Quiz
•
11th Grade
10 questions
Arrays
Quiz
•
11th Grade
10 questions
Artificial Intelligence
Quiz
•
11th Grade
10 questions
Explorando Tinkercad en Secundaria
Quiz
•
7th Grade - University
Popular Resources on Wayground
5 questions
This is not a...winter edition (Drawing game)
Quiz
•
1st - 5th Grade
15 questions
4:3 Model Multiplication of Decimals by Whole Numbers
Quiz
•
5th Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
10 questions
The Best Christmas Pageant Ever Chapters 1 & 2
Quiz
•
4th Grade
12 questions
Unit 4 Review Day
Quiz
•
3rd Grade
10 questions
Identify Iconic Christmas Movie Scenes
Interactive video
•
6th - 10th Grade
20 questions
Christmas Trivia
Quiz
•
6th - 8th Grade
18 questions
Kids Christmas Trivia
Quiz
•
KG - 5th Grade
