A Ternary Operator
The conditional operator (?:) is closely related to the if / else structure.
The ?: is C++’s only ternary operator. Whereas a binary operator takes two parameters, a ternary operator takes three.
Previous slide
Next slide
Back to first slide
View graphic version