posted 14 years ago
I can not get the ternary operator to work.
What is wrong with this code?
I'm getting these compile errors from eclipse.
Multiple markers at this line
- Syntax error on token "?", ; expected
- Syntax error on token ":", ; expected
But of course if I put in the semi-colons, it does not help:
Multiple markers at this line
- Syntax error on token ":", invalid EmptyStatement
- Syntax error on token "?", delete this token
I have this same problem every time I try to use the ternary operator. What the heck am I doing wrong?
Thank you in advance.
TDR