First page Back Continue Last page Graphics
const string greeting = "Hello, " + name + "!";
const promises that we will never change this variable again.
const definitions MUST be initialized when defined.
This definition can use the values of previous variables as it does here.
+ is a concatenation operator within the string object. ("x"+name, name+"x", name+name, but NOT "x"+"x");
Example of overloading the + operator.