Question Detail
Question
What is the result of
len("Python 3")?
Correct Answer
Option B is the correct answer.
Detailed Explanation
The
len() function counts all characters, including spaces. 'Python' has 6 characters, '3' has 1 character, and there's 1 space between them. So, 6 + 1 + 1 = 8. This is also confirmed in the 'Predict the Output!' section (page 11).
Hint
Don't forget to count spaces when using
len().