0
Trying to create a program to translate string to pig Latin. Please help!
How do I make what Iām trying to do, apply to every word in the string? Iāve been messing around with different indexes but I canāt figure it out. My code: https://sololearn.com/compiler-playground/c69aUikdF68X/?ref=app
2 Answers
+ 4
Play with the code and try to find out how this work. That is similary to a list.
+ 1
Josh Rhodes, I recognize your name these days and you are asking more than 1 code coach question in a day.
Try to solve the easy questions first then move on to the medium, no jumping around.
Starting from easy builds your experience, and gets better knowledge how the functions work.
Back to your question, each word has to be transformed into pig Latin.
To accomplish this you can loop through the words as JaScript already gave you a hint.
Indexing is not relevant here.
Also take a closer look to the task description, what the input contains or NOT contains, then split the words correctly.
After the words are split you can manipulate each word individually in a loop.