Learn the Date Object by Building a Date Formatter - Step 19

Tell us what’s happening:

I believe I have written the code correctly but I still get the same error. I am following the example on this step, I tried googling it, and I even consulted with an AI. And I can’t seem to find where the error is.

Your code so far


const exampleSentence = "selur pmaCedoCeerf";
exampleSentence.split("");
console.log(exampleSentence);

Your browser information:

User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/116.0.0.0 Safari/537.36

Challenge Information:

Learn the Date Object by Building a Date Formatter - Step 19

You made more changes to this line than were requested.

Update your split method, to use an empty string as a separator. Open up the console again to see the result.

Only change the arguments to .split(). Make no other changes.

As mentioned earlier, you need to modify the existing line here from the original code

const exampleSentence = "selur pmaCedoCeerf".split();

but looking at the example, I can see why you arrived at that solution.

We could update the example to essentially be this

// returns ["h", "e", "l", "l", "o"]
"selur pmaCedoCeerf".split("");

Thank you! of course, it worked. I was following the example too strictly, I guess :sweat_smile:

Thank you! I understand now, I was following the example too strictly. Still too noob to deviate from examples that much :smile: