freeCodeCamp Challenge Guide: Declare a Read-Only Variable with the const Keyword

Declare a Read-Only Variable with the const Keyword


Problem Explanation

Change the code so that all variables are declared using let or const .


Hints

Hint 1

  • You should change fCC to all uppercase.

Hint 2

  • FCC should be a constant variable declared with const .

Hint 3

  • fact should be declared with let .

Hint 4

  • console.log should be changed to print the FCC and fact variables.

Solutions

Solution (Click to Show/Hide)
const FCC = "freeCodeCamp";
let fact = "is cool!";

fact = "is awesome!";
console.log(FCC, fact);

Relevant Links

27 Likes