Question Detail
Question
Which of the following Python statements correctly creates a multi-line string?
Correct Answer
Option B is the correct answer.
Detailed Explanation
Option B uses triple quotes, which are specifically designed in Python to enclose multi-line strings. The
\n character in Option A would create a new line, but the question asks about the method of creating a multi-line string directly via quotes. Option C is concatenation, not multi-line string creation. Option D creates a tuple of strings.
Hint
Recall the three main ways Python offers to enclose text, especially for text spanning multiple lines.