Question: What does evaluation of variable mean?

```
int main(){
   int variable;
   variable;
}

```

What does "variable" do? Why evaluation of "variable" should produce its own value?

Answer: 
Evaluating basically means "executing the code".

In an expression, `variable` "loads" an `int` containing the value of that variable into the CPU.

Evaluating the statement `variable;` "loads" that value to the CPU, which then does nothing with it. (The compiler is smart enough to detect that nothing happens, and will just ignore this. If you're lucky, it'll also produce a warning letting you know that this does nothing and that's suspicious.)

Evaluating the statement `int a = variable;` "loads" that value to the CPU, and then assigns it to a new local named `a`.
In C++, as with other languages, *expressions* are *evaluated*, typically to return a singular value. This happens by following the [operator precedence rules](https://en.cppreference.com/w/cpp/language/operator_precedence) to apply operators in the correct order.1

In the simplest case:

```
int x = 2;
int y = x + x * x;

```

Where the *right-hand-side* (relative to the `=` assignment operator) of the expression requires evaluation in each case. In the first statement it's easy, it's just `2`. In the second the evaluation order rules apply and you get `2 + 4` or `6`.

Evaluation is the process of applying *every* operator in the correct order which will yield a singular value, the result of that expression.

Think about evaluation as similar to how you might when determining the result of a mathematical formula. Different rules apply, but the principles are the same.

---

1 The order arguments are evaluated may not necessarily be the order in which they're defined.