What is the use and syntax of ternary operator
Answers
Answered by
12
syntax of ternary operator::
result= true statement?value1:value2;
the ternary operator is short form of if..else..statement and it is also useful in saving the space as it takes few space and it is convenient to use.
result= true statement?value1:value2;
the ternary operator is short form of if..else..statement and it is also useful in saving the space as it takes few space and it is convenient to use.
Similar questions
Chemistry,
7 months ago
English,
7 months ago
Computer Science,
1 year ago
Math,
1 year ago
English,
1 year ago