Search Header Logo

Python strings

Authored by dhruv patel

Computers

University

Used 1+ times

Python strings
AI

AI Actions

Add similar questions

Adjust reading levels

Convert to real-world scenario

Translate activity

More...

25 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Media Image

What letter will be printed on the screen after running this code:

e
x
t
Nothing prints

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

What output will this code produce?

Exeter
4
6
city

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

What output will this code produce?

Exeter
4
6
city

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

word = "amazing"


For the given string if we run word[2:5] , what would the result be?

mazi

mazin

azi

azin

5.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Which of the following is not a valid string function?

isalphanumeric

isspace

islower

isalnum

6.

FILL IN THE BLANKS QUESTION

1 min • 1 pt

string="HELlo"

What will be the result of string.isupper()?

(a)  

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is printed by the following statement?

print("P" not in "APCSP")

True

False

Error

Access all questions and much more by creating a free account

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Microsoft

Continue with Microsoft

or continue with

Facebook

Facebook

Apple

Apple

Others

Others

By signing up, you agree to our Terms of Service & Privacy Policy

Already have an account?