...

/

Quiz on Strings and Lists

Quiz on Strings and Lists

Test your knowledge of strings and lists in Python.

We'll cover the following...
1

(Select all that apply.) We want to store the following string in the variable msg. Which of the following shows the correct syntax in Python?

This string has text1 and text2 in it
A)

msg = '''This string has text1 and text2 in it'''

B)

msg = 'This string has text1 and text2 in it"

C)

msg = "This string has text1 and text2 in it"

D)

msg = "This string has text1 and text2 in it"

Question 1 of 60 attempted
Access this course and 1400+ top-rated courses and projects.