Advanced freeCodeCamp • top-learn-data-types-and-conditionals

Learn Data Types and Conditionals Lesson B

Lesson Overview

Now that you have gone through the points listed in the assignment of the previous challenge, you should have a good understanding of how strings can be manipulated in JavaScript.

Now that you have gone through the points listed in the assignment of the previous challenge, you should have a good understanding of how strings can be manipulated in JavaScript.

Currently, this given string has a trailing space at the end after the exclamation mark. To solve this, you need to remove the trailing space from the string using a predefined method.

let greeting = "Hello World!  ";

console.log(greeting);

Link to Guide