Equations, expressions, and assignment-statments

In C++ (and every other programming language I know of) the equal sign is the *assignment operator*. It *assigns* the **value on the right** to the **variable on the left.** This means that everything on the right must be defined (known). And, the expression on the right must evaluate to a value.

x = 3; //OK

y = x + 3; //OK if x is defined

c = (5.0/9.0 * (f – 32) ); / /OK if f is defined

2 = x; //NO!

x + 2 = 3; // NO!

Note that you might have to put decimals in 5.0/9.0 so that the compiler stores the division-result as a float.