Short IF ELSE syntax in objective C
It's exactly the same in both languages, except you typically don't find
$ signs in Objective-C variable names.
if(value)return 1;elsereturn 0;
You should also keep in mind that the conditional operator
?: isn't a shorthand for an if-else statement so much as a shorthand for a true vs false expression. See the PHP manual.