What is the syntax for ternary operator in C?

C Programming Language >   Operators and Enums in C Language >   Conditional Operator in C  

Short Question

715


Answer:

Ternary operator is same as if else control statement in C.

Syntax : (Condition? true_value: false_value);

Example: (A > 100? 0: 1);


This Particular section is dedicated to Question & Answer only. If you want learn more about C Programming Language. Then you can visit below links to get more depth on this subject.




Join Our telegram group to ask Questions

Click below button to join our groups.