var myName = "Esla";
var myStr = "My name is " + myName " + " and I am well!";
i’ve tries this but it ain’t working
var myName = "Esla";
var myStr = "My name is " + myName " + " and I am well!";
i’ve tries this but it ain’t working
What you should have:
var myName = “Esla”;
var myStr = “My name is " + myName + " and I am well!”;
What you have:
var myName = “Esla”;
var myStr = “My name is " + myName " + " and I am well!”;
Watch out for those typos.
I’ve edited your post for readability. 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.
See this post to find the backtick on your keyboard. The “preformatted text” tool in the editor (</>
) will also add backticks around text.
Note: Backticks are not single quotes.
see you have done a mistake “String” + “String” “+” -> will not work cos it will treat an operator as a string and +, / , <> are operator so do your assignments properly