Errors using ternary operator in c
In C the ternary operator is defined like logical-OR-expression ? expression : conditional-expression where conditional expression is defined like logical-OR-expression The assignment operator has a lower priority than the OR operator. Thus you have to write a >= 5 ? b = 100 : ( b = 200 ); Otherwise the compiler consideres the expression … Read more