Conditional operator: It is an operator taking three operands that is, a ternary operator. The conditional operator (?:) is employed in the form
bexpr ? expr1 : expr2
Here bexpr is a Boolean expression. If Boolean expression has value true then the outcome of the operation is the value of expr1, or else it is the value of expr2.