Skip to content

rdionis/pig-latin

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 

Repository files navigation

#PIG LATIN TRANSLATION

Create a function that takes a string of words and moves the first letter of each word to the end of it, then adds ‘ay’ to the end of the word. This is a basic form of “Pig Latin”. a) Move the first letter of each word to the end of the word. b) Add “ay” to the end of the word. c) Words starting with a vowel (A, E, I, O, U) append “way” to the end instead.

Extra Practice Preserve proper capitalization as in the examples below. Examples: pigLatin(“Cats are great pets.“) ➞ “Atscay areway reatgay etspay.” pigLatin(“Tom got a small piece of pie.“) ➞ “Omtay otgay away allsmay iecepay ofway iepay.” pigLatin(“He told us a very exciting tale.“) ➞ “Ehay oldtay usway away eryvay excitingway aletay.”

About

Pig Latin JavaScript exercise

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors