Python has a method called len() that gives us the length of any composite object. To get the length of a string, just pass the string to the len() call. For example,
print(len('abcdefghijklmnopqrstuvwxyz'))
OUTPUT
26
Python has a method called len() that gives us the length of any composite object. To get the length of a string, just pass the string to the len() call. For example,
print(len('abcdefghijklmnopqrstuvwxyz'))
OUTPUT
26