Programming Code Center(PCC)
[JS]

(PCC)::[How-to-perform-Adding-JavaScript-strings]::[js]

File Name : index.html

<!DOCTYPE html>
<html>
<body>

<h2>JavaScript Variables</h2>

<p>The result of adding "John" + " " + "Doe":</p>

<p id="demo"></p>

<script>
var x = "John" + " " + "Doe";
document.getElementById("demo").innerHTML = x;
</script>

</body>
</html>

Output :

JavaScript Variables

The result of adding "John" + " " + "Doe":