Describe your issue in detail here.
Hi all, I have followed all the hints to this challenge an tried my best but my code is still wrong. as can bee seen down below the original code was
var fCC = "freeCodeCamp"; // Change this line
var fact = "is cool!"; // Change this line
fact = "is awesome!";
console.log(fCC, fact); // Change this line
and here is what the challenge asked;
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.
please look at my code so far down below and let me know what I have done wrong. I followed the hints and changed what was asked to change yet I am still stuck in this particular challenge. I appreciate any help. many thanks.
Your code so far
const fCC = "freeCodeCamp"; // Change this line
let fact = "is cool!"; // Change this line
fact = "is awesome!";
console.log(fCC, fact); // Change this line
Your browser information:
User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/100.0.4896.127 Safari/537.36
Challenge: Declare a Read-Only Variable with the const Keyword
Because it is declared as a constant they want you to use all caps in the name. After that you also need to change the console.log to use it with the new name.
Hi. It looks like you’ve shared the challenge’s starter code, but not your own code. Could you please show us what you’ve written so we can help you debug it?
When you enter a code block into a forum post, please precede it with a separate line of three backticks and follow it with a separate line of three backticks to make it easier to read.
You can also use the “preformatted text” tool in the editor (</>) to add backticks around text.
Its telling you to change the variable name to uppercase, not the value which is the string. And javascript is case sensitive, CONST != const. The console.log as its name implies will log things to the console. In this example if you put the variable names in console.log, it will display there values in the console.
i think this is what @Lego_My_Eggo is trying to say const should stay the same but if you read the entire text on the left it will tell you what should be uppercase and what should be lower case !