
String manipulation class11
Authored by Rohit E
Computers
9th - 12th Grade
Used 3+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Negative index (-1) belongs to which character of a string
first character
last character
second last character
second character
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following functions will return the string in all caps?
to.upper()
is.upper()
upper()
all-upper()
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the correct output?
True False
False True
False False
True True
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Choose the correct function to get the ASCII code of a character:
char('char')
All of these
ascii('char')
ord('char')
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
str1 = 'Waha'
print(str1[:3] + 'Bhyi' + str1[-3:])
Wah Bhyi Wah
WahBhyiWah
WahBhyiWaha
WahBhyiaha
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Functions capitalize() and title() return the same result.
False
True
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What will be the result of this code: ‘*’ * 3
***
Error
*3
3*
Access all questions and much more by creating a free account
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?