you don't need console.log() to print out the string values. Its just for the formality of the exercise.
The code editor you type into by default is a console that you're constantly logging values into. So regardless,
it still works either way.
And one more thing. Why you would want to use a console.log() : Since there are different existing variables with accessible values often created while programming, you'll need to use a console.log() to specifically print out the result you want.
you create a variable in your console or programming editor.
and you store the value 2 inside it.
var x = 2;
if you type "x" in the console, it print out the value 2 for you. Because it knows you stored two inside it.
But what if in your programming editor have to values;
var x = 3;
var y = 4;
Now the console will ignore the first line of code which is 3 and print 4
why? Because computers read programs line by line.
so it will read line 3 then jump and print out line 4
That means in your console you get the value "Y". what is equal to 4 as your result .
Now if you're being specific and you want to get a result of, say 3 + 4;
then you have to use the console.log() function to get the result
console.log(y + x);
So far, we can say that console.log allows us to be more specific with the type of result output we want not withstanding the infinite number of existing values.