Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
wymeczone solution in Clear category for Bird Language by mijalskihubert
VOWELS = "aeiouy"
SPACE = " "
def translation(phrase):
slowo=""
usun=0
for x in phrase:
print(x)
if usun==0:
print("literka to, ",x)
if x not in VOWELS:
if x not in SPACE:
print("nie jest spacja ani vowel")
slowo+=x
usun=2
if x in VOWELS:
print("jest vowel")
slowo+=x
usun=3
if x in SPACE:
slowo+=x
print("jest spacja")
if(usun>0):
usun-=1
return slowo
if __name__ == '__main__':
#These "asserts" using only for self-checking and not necessary for auto-testing
assert translation("hieeelalaooo") == "hello", "Hi!"
assert translation("hoooowe yyyooouuu duoooiiine") == "how you doin", "Joey?"
assert translation("aaa bo cy da eee fe") == "a b c d e f", "Alphabet"
assert translation("sooooso aaaaaaaaa") == "sos aaa", "Mayday, mayday"
Nov. 9, 2016