Question: I'm looking for a fully accurate statement of an algorithm to count syllables in words. What I'm finding when I research is inconsistent or what I know to generate incorrect results. Does anyone have any suggestions of how to accomplish this? Thanks.

The algorithm I'm using now:

1. Count the number of vowels in the word.
2. Do not count double-vowels ("rain" has 2 vowels but is only 1 syllable)
3. If last letter in word is vowel do not count ("side" is 1 syllable)

Are there any more rules I'm missing? I'm trying to determine in testing for my incorrect results if the algorithm I'm using is wrong or my implementation of it.

Answer: 
> 
> I'm looking for a fully accurate statement of an algorithm to count
>  syllables in words
> 
> 
> 

There isn't one. Period. Whatever algorithm you invent, I promise to find a counterexample. In certain languages(Armenian and Russian come to mind) the algorithm is pretty straightforward - count the number of vowels. In other languages, such as German, it's not as straightforward but still doable. In English, I am afraid, the transduction between letters and sounds is absolutely irregular. 

For example, 

***coincidence***. ***oi*** is to be counted as two syllables. But in ***boil*** it's only one syllable.
Also, not counting the final vowel is not always accurate. Consider the name ***Penelope*** or ***Hermione***. Or ***banana***

Another curious case is when the syllable exists without a printed vowel. For example, ***table*** is a bisyllabic word but the second syllable is generated by the invisible sound between ***b*** and ***l***. Also, don't forget about words originated from greek, which can have a lot of consecutive vowels. E.g. ***onomatopoeia***. 

So, there is no accurate algorithm. The only way you can go is to try to find an algorithm which works in many (I am avoiding the word most) cases. But in this case you should redefine your requirements.
from typing import Counter

```
def splitting_into_syllables(input_word):
    count = 0
    word1 = input_word.lower()
    vowels = set("aeiou")
    syll = list()
    temp = 0
    for letter in word1:
        if letter in vowels:
         count += 1
    if count == 1:
        print(count)
        return word1
    for index in range(1,len(word1)):
        if word1[index] in vowels and word1[index - 1] not in vowels:
            w = word1[temp: index+1]
            print(w)
            if len(w) != -1:
                syll.append(w)
                temp = index+1

    print(count)

user_input = input()
print(splitting_into_syllables(user_input))

```