21st Jun 2022, 12:01 PM
Aisy Danish Mohd Nazry
Aisy Danish Mohd Nazry - avatar
3 Answers
+ 1
Do you wanna count words in string? Count is used to count how many times some word or letter exist in string, so it wont work if your string is "asv bgi", also you add letter by letter using for loop Read this to learn how to use count https://www.w3schools.com/JUMP_LINK__&&__python__&&__JUMP_LINK/ref_string_count.asp This is how to counti words in string, it use str.split() to split words by white space, then count it using len() https://www.adamsmith.haus/python/answers/how-to-count-the-number-of-words-in-a-string-in-python
21st Jun 2022, 2:22 PM
PanicS
PanicS - avatar
0
Aisy Danish Mohd Nazry What you want to try to do?
21st Jun 2022, 12:07 PM
A͢J
A͢J - avatar