7.11 — Static local variables

The term static is one of the most confusing terms in the C++ language, in large part because static has different meanings in different contexts. In prior lessons, we covered that global variables have static duration, which means they are created when the program starts and destroyed when the program …

O.2 — Bitwise operators

The bitwise operators C++ provides 6 bit manipulation operators, often called operators: Operator Symbol Form The operation returns a value where: left shift << x << n the bits from x are shifted left by n positions, new bits are 0. right shift >> x >> n the bits from …

6.8 — Logical operators

While relational (comparison) operators can be used to test whether a particular condition is true or false, they can only test one condition at a time. Often we need to know whether multiple conditions are true simultaneously. For example, to check whether we’ve won the lottery, we have to compare …