number of characters in a string in Python
number of characters in a string in Python
There are a function which is count the total length of list or object but if we want count only characters in a string then there are some ways to do it but here i am giving you a very easy step to it.Lets see an example of it.
- x="how r u"
- y=x.split(" ")
- print(len("".join(y)))
Comments
Post a Comment