5 exercises on saying arithmetic and logical operators aloud.
0 / 5 completed
1 / 5
How is the "%" operator read aloud in programming (e.g. a % b)?
The % symbol is named "percent" /pərˈsɛnt/, but as a programming operator (remainder) it is read "modulo" /ˈmɒdjʊloʊ/ or just "mod". So "a percent b" or, more meaningfully, "a mod b" / "a modulo b." For example "7 mod 3 is 1." Do not read it as "divide" — it gives the remainder, not the quotient. The symbol's name is "percent"; its operator meaning is "modulo."
2 / 5
How is "++" (the increment operator, e.g. i++) read aloud?
The ++ operator is read "plus plus". So "i++" is said "i plus plus," and you can also describe it as "increment i" (increase by one). The language C++ is itself read "C plus plus" /siː plʌs plʌs/, using the same operator name. Do not say "double plus" or "add add." Each plus sign is spoken: "plus, plus." Likewise "--" is "minus minus" or "decrement."
3 / 5
How is "!=" (the inequality operator) read aloud?
The != operator is read either as "not equal(s)" (describing its meaning) or as "bang equals" (describing the symbols, since "!" is nicknamed "bang"). Both are widely accepted. So "if a not-equals b" or "if a bang-equals b." The "!" alone is called "bang" or "exclamation mark" (or "not" as a logical operator). Either reading is professional; "not equals" is clearer to beginners.
4 / 5
How is "==" (the equality comparison) read, and how does it differ from "="?
The == operator is read "equals equals" or "double equals" (comparison: are they equal?), while a single = is read "equals" (assignment: set this value). So "if x double-equals 5" versus "x equals 5" (assign). The distinction matters greatly in speech to avoid confusion between comparison and assignment. JavaScript's "===" is "triple equals" or "equals equals equals" (strict equality).
5 / 5
How is "&&" (logical AND) read aloud?
The && operator is read "and and" or "double ampersand", and means logical AND. So "if a and-and b" tests that both are true. A single "&" is the ampersand /ˈæmpərsænd/ (bitwise AND, or "address-of" in C). So "&&" can be described as "double ampersand" or simply read as "and." Likewise "||" is "or or" / "double pipe" (logical OR). Do not say "amp amp" formally — "ampersand" is the symbol's name.