Use the programming interface to solve this problem.
Now that we know how to convert from English to Pig Latin, can we reverse the translation? Given a sentence in Pig Latin, reverse it and try to find the original English text.
Be careful to note that if a Pig Latin word is capitalized, like "Arispay", the original English word is "Paris" rather than "pAris". Case counts!
ID: piglatin2
Input: A sentence in Pig Latin.
Output: The translation in English.
Read the input from a file called piglatin2.in
that's in the current working directory, and then write your output to a file called piglatin2.out
.
Work backwards! You'll probably need the chr()
and ord()
functions! Also, string splicing is pretty cool in Python ;)
None yet!