As with algebra, you can do arithmetic with JavaScript variables, using operators such as = and +:
var x = 5 + 2 + 3; (value of x is 10)
You can also add strings, but strings will be concatenated (added end-to-end):
var x = "John" + " " + "Doe"; (value of x is John Doe)
As shown in the example below, if you add a number to a string, the number will be treated as string, and concatenated:
var x = "5" + 2 + 3; (value of x is 523)