Skip to content
Advertisement

How can I edit this code so that it prints the result a certain way?

I’m trying to get this code:

JavaScript

To print the result like this:

JavaScript

Advertisement

Answer

change your print statement for this one

JavaScript

n is the new line character, that’s why.

User contributions licensed under: CC BY-SA
3 People found this is helpful
Advertisement