Declare a Read-Only Variable with the const Keyword

Change the code so that all variables are declared using let or const. Use let when you want the variable to change, and const when you want the variable to remain constant. Also, rename variables declared with const to conform to common practices, meaning constants should be in all caps.

const FCC = "freeCodeCamp"; // Change this line
let Fact = "is cool!"; // Change this line
let fact = "is awesome!";
console.log(FCC, fact); // Change this line
0 0 votes
Article Rating
Was this article helpful?
YesNo
Subscribe
Notify of
guest

0 Comments
Most Voted
Newest Oldest
Inline Feedbacks
View all comments
Scroll to Top