What is the syntax for ternary operator in C?

Short Answer
Views 679

Answer:

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

Syntax : (Condition? true_value: false_value);

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

Related Articles:

This section is dedicated exclusively to Questions & Answers. For an in-depth exploration of C Programming Language, click the links and dive deeper into this subject.

Join Our telegram group to ask Questions

Click below button to join our groups.