We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
- Prepare
- Python
- Debugging
- Words Score
- Discussions
Words Score
Words Score
Sort by
recency
|
162 Discussions
|
Please Login in order to post a comment
Just the ++score has to be converted into score += 1. Rest of the code stays as it is.
With the use of regex and list comprehension -->
Regular resolution of this problem -->
As we all know that vowels are a,e,i,o,u and why it has metioned y in the above one.
"y" is a vowel or a consonant depends on its position and the sound it represents in the word. This versatility makes "y" quite special in the English alphabet!
So in this case it could be either, but as it was mentioned as being counted as a vowel, we should take it as a vowel