Which Python function returns the length of an object?
-
A
count()
-
B
length()
-
C
len()
Correct answer
-
D
size()
15 views
Explanation
The len() function returns the number of items in an object like list, string, or tuple.
Doubts & discussion
Not sure why the answer is C? Ask here and get an explanation.
Ask a doubt about this MCQ