Answers for "insert variable in string javascript"

10

how to put variable in string javascript

var myInt = 1
console.log(`my variable is ${myInt}`);
// my variable is 1
Posted by: Guest on July-27-2020
0

insert variable in string javascript

var a = 5;
var b = 10;
console.log(`Fifteen is ${a + b}.`);
// "Fifteen is 15.
Posted by: Guest on June-23-2021

Code answers related to "insert variable in string javascript"

Code answers related to "Javascript"

Browse Popular Code Answers by Language