What is a variable in C++?
A variable is a value of some type (object, int, string, double) that has been given a name.
What is Definition of a variable?
This is the actual naming and instantiation of the variable (giving it an address in RAM).
What is Instantiation of a variable?
Allocating an address to the variable in memory.
What is the difference between an l-value and an r-value?
An l-value is a value that gets a persistent address in memory, an r-value is typically an equation or some other value that can include a previously defined l-value, that is used to compute an l-value.
What is an uninitialized variable and what kind of behaviour can you expect from such a variable?
An uninitialized variable is a variable that has been defined, but not assigned a value. If this variable is called in this state, it will return random nonsense (in respect to our program) as it has assigned whatever was last stored in that memory location.
What is undefined behaviour?
Undefined behaviour includes program crashing, inconsistent results from program and other inconsistencies that are caused by uninitialized variables being included in the program. This is considered to be behaviour that is not well defined by the language.