Rewrite the following using ternary operator
if (a>=18)
c=20
else
c=15
Answers
Answered by
1
Question:-
- Rewrite the following using ternary operator
if(a>=18)
c=20;
else
c=15;
Answer:-
c=(a>=18)? 20:15;
Similar questions