请问这个是不是因为c的格式有误?还是别的选项?

img

len( str )
比如:

str_ = 'how old are you'
str_1 = ['how', 'old', 'are', 'you']
print(len(str_))
print(len(str_1))

字符串,列表都是可以len(str)的
如果非得str.的形式的话,可以尝试这种

str_ = 'how old are you'
print(str_.__len__())

也是可以出结果的