Strings in python - Test

Strings in python - Test

11th Grade

50 Qs

quiz-placeholder

Similar activities

Project STEM Unit 1 Review

Project STEM Unit 1 Review

9th - 12th Grade

49 Qs

Python Final Exam

Python Final Exam

9th - 12th Grade

46 Qs

PCEP Questions

PCEP Questions

9th - 12th Grade

46 Qs

Python Practical Questions

Python Practical Questions

9th - 12th Grade

46 Qs

GCSE Python Legends

GCSE Python Legends

1st - 12th Grade

45 Qs

Python Review - PLTW CSE / Codecademy

Python Review - PLTW CSE / Codecademy

9th - 12th Grade

53 Qs

STRINGS

STRINGS

11th Grade

45 Qs

រំឮកមេរៀនPython

រំឮកមេរៀនPython

11th Grade

45 Qs

Strings in python - Test

Strings in python - Test

Assessment

Quiz

Computers

11th Grade

Hard

Created by

Sangeetha John

Used 89+ times

FREE Resource

50 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

45 sec • 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

45 sec • 1 pt

Which of the operator can be used in Strings?

+

*

Both of the above

None of the above

3.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

Python accepts single ('), double (") and triple (''' or """) quotes to denote strings. Which of the following is NOT acceptable Python syntax?

print('Hello World')

print("Hello World")

print('Hello World")

print(""'Hello World'"")

4.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

What is printed by the following statement?

print("P" not in "APCSP")

True

False

Error

5.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

What is printed by the following statement?

print("A" in "APCSP")

True

False

Error

6.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

For strings, the + operator represents

Concatenation

Addition

Appending

Recantation

7.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

data = "No Way!" The expression len(data) evaluates to:

7

9

8

6

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?