Ternary conditional operator: Difference between revisions

Content deleted Content added
Jesin (talk | contribs)
I think this deserves some mention. It could probably be said better, but it's better than saying nothing.
Line 59:
In this case there's no possibility to replace the use of ?: operator with '''if-else''' statement. (Although we can replace the use of ?: with a call to a custom inline function, inside of which can be an ''if-else'' statement.)
 
====[[Python (programming langagelanguage)|Python]]====
The Python programming language uses a different syntax for this operator:
<source lang="python">value_when_true if condition else value_when_false</source>