Reverse string challenge

i wrote down apples and rewrote it starting from the last word s down to the begining of the letter a

Ok. That sounds reasonable.

So you started with

APPLES

Then you put down a

S

and then where does the E go?

on reverse E falls on the second letter

Ok, well that makes sense.

This loop seems to go through the word backwards. How do I get letters out of a string?

loop through starting from index zero

I understand that we want a loop. But your loop doesn’t seem to be doing anything that looks like getting letters and writing them down. So how do you get a letter from the string?

chart()?? are my correct??

I’m not familiar with the chart() method.

Instead of guessing syntax, it is better to look up syntax:

yaa. i remembered now bracket notation

Hi @columbuschidozie1,

Just to give an information which i feel you should know.

str.split("");

The above line of does not mean anything unless you store the results into a variable.
Because, Strings in JavaScript are immutable. This means that you cannot modify an existing string, you can only create a new string.

4 Likes

MOD EDIT: Solution Redacted

It is great that you solved the challenge, but instead of posting your full working solution, it is best to stay focused on answering the original poster’s question(s) and help guide them with hints and suggestions to solve their own issues with the challenge.

Gotcha sorry about that…

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.