When in Rome...
Switch branches/tags
Nothing to show
Permalink
Failed to load latest commit information.
.gitignore
README.md added corrected formatting Apr 3, 2013

README.md

When In Rome, Speak Pig Latin

Isthay atakay isway ittenwray entirelyway inway Igpay Atinlay.

Not really. But it is about making English look weird like that.

Your goal is write a function that converts English into Pig Latin. Here's a rules refresher

Rules

  • Words that start with a vowel have -way added to the end of them. So, for example, apple becomes appleway.
  • Words that start with a consonant have that consonant placed at the end of the word and -ay added to the end. For example, bear becomes earbay.
  • Words that start with multiple consonants have all the consonants placed at the end and -ay added. So, church becomes urchchay.

That's it.

Hints

The algorithm here is actually pretty simple. So, try to take really small steps. Start with single words and then add the ability to translate sentences. Focus on test driving all the vowels individually. Make the tests as tiny as possible.