Answers for "how to count number of characters in a word in python"

1

pyton count number of character in a word

# Count number of characters in a string (word)
a = "some string"
print len(a)       # 11
Posted by: Guest on September-20-2020
0

count number of words in a string python

a_string = "you string here"
word_list = a_string.split()
number_of_words = len(word_list)
print(number_of_words)
Posted by: Guest on February-12-2022

Code answers related to "how to count number of characters in a word in python"

Python Answers by Framework

Browse Popular Code Answers by Language