Simple question on Space


#1

Hi,
This may be a stupid question, but I am unable to get over it; hence, requesting your help to understand the concept.
Consider the following code snippet:

console.log("My Name is" +" "+ xyz);

In multiple places, I have seen that for adding an extra space, we are using +" "+ - I am wondering why can't we give the space along with the statement itself? for example, I can rewrite the above code as:

console.log("My Name is " +xyz);

Is this because of some coding standards or does it have some other purpose?


#2

There's nothing special about the space character, just mash it in there.