Search Header Logo

String Manipulation Quiz

Authored by Mark Halfyard

Computers

12th Grade

String Manipulation Quiz
AI

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

What is the purpose of string manipulation?

To extract characters from a string

To create a new string

To change the font of a string

To add colors to a string

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What command is used to get the length of a string?

len(string)

string.len()

length(string)

string.length()

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which command is used to convert a string to uppercase?

string.uppercase()

toUpperCase(string)

string.upper()

string.toUpper()

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What does the substring command do?

Returns the entire string

Returns part of the string

Reverses the string

Counts the number of characters in the string

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How is concatenation of strings achieved?

Using the join command

Using the merge command

Using the append command

Using the addition or plus operator

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the purpose of the ASC command?

Returns the character from the ASCII number

Counts the number of characters in a string

Converts a string to lowercase

Returns the ASCII value of a character

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

In Python, what is the equivalent of string.length()?

len(string)

string.len()

string.length

length(string)

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

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

Already have an account?