subject
English, 16.10.2020 14:01 colbygreen6189

Pig Latin is childish encoding of English that adheres to the following rules: 1. The vowels are 'a', 'e', 'i', 'o', 'u', as well as any 'y' that is not the first letter of a word. All other letters are consonants. For example, 'yearly' has three vowels ('e', 'a', and the last 'y') and three consonants (the first 'y', 'r', and 'l').
2. If the English word begins with a vowel, append 'hay' to the end of the word to get the Pig Latin equivalent. For example, 'ask' becomes 'askhay, 'use' becomes 'usehay'.
3. If the English word starts with 'q', assume it is followed by 'u'; move 'qu' to the end of the word, and append 'ay'. Hence 'quiet' becomes 'ietquay', 'quay' becomes 'ayquay'.
4. If the English word begins with a consonant, move all the consonants up to the first vowel (if any) to the end and add 'ay'. For example, 'tomato' becomes 'omatotay', 'school' becomes 'oolschay', 'you' becomes 'ouyay', and 'h' becomes 'hay'.

Required:
Your goal is to write a function pigify that take a single English word (e. g. a string with only letters and no spaces), and converts it into Pig Latin.

ansver
Answers: 1

Another question on English

question
English, 21.06.2019 21:50
Time remaining 59: 46 which central idea should be included in a paraphrase of this excerpt? read the excerpt from the odyssey. out to sea again! ' my men were mutinous, fools, on stores of wine. sheep after sheep they butchered by the surf, and shambling cattle, feasting.-while fugitives went inland, running to call to arms the main force of cicones this was an army, trained to fight on horseback or, where the ground required, on foot. they came with dawn over that terrain like the leaves and blades of spring. so doom appeared to us, dark word of zeus for us, our evil days. the forces sent by cicones to fight odysseus and his men arrived during the early morning hours. odysseus and his men feasted on the animals they slaughtered while on the island of cicones the forces sent by cicones to stop the plundering of odysseus and his men were skilled and powerful odysseus views the forces sent by cicones as punishment from the greek god zeus. mark this and retum save and exit save and exit next sub subunit
Answers: 1
question
English, 22.06.2019 01:20
Write an explanation for how to perform some kind of physical activity, such as riding a bike or playing a sport. the explanation should be geared toward someone who has never performed the activity. be sure to explain the steps in the process clearly, organize your ideas appropriately, use text features
Answers: 3
question
English, 22.06.2019 03:00
How do headings organize your information?
Answers: 1
question
English, 22.06.2019 03:00
Need answer asap plz! in “ode to the west wind,” which image best expresses the speaker’s hopes for the west wind? a. “scatter, as from an extinguished hearth / ashes and sparks . .” b. “make me thy lyre, even as the forest is . .” c. “. . he lay, / lulled by the coil of his crystalline streams . .” d. “if i were a dead leaf thou mightest bear . .”
Answers: 2
You know the right answer?
Pig Latin is childish encoding of English that adheres to the following rules: 1. The vowels are 'a...
Questions
question
Chemistry, 14.03.2020 22:27
Questions on the website: 13722363