ternary operator c++

I have written below code but it is giving error. How to fix it and correctly use ternary operator in c++? https://code.sololearn.com/cabPunzipfOp

15th Feb 2022, 5:00 PM
Gajendra Sonare
Gajendra Sonare - avatar
2 Answers
+ 2
"continue" and "break" are statements, not expressions.
15th Feb 2022, 5:20 PM
Arsenic - avatar
break and continue doesn't make any sense in your code that's why you are getting error.. Do you just want to know how to use ternary operator ???
15th Feb 2022, 5:17 PM
Davinder Kumar
Davinder Kumar - avatar