meta
meta copied to clipboard
Tag: Ternary Operator
Description
A new tag that explains the following:
- Ternary operator syntax.
- How is it different from a regular if-else statement.
- Examples.
A different approach
Since we don't already have a tag for if-else
, we could have 1 tag for both if-else
and ternary operator
, stating their differences and syntax
or
we could skip the if-else
if it seems to be quite basic.
yesssss i would love this!
I don't think the demand for an if-else
tag is there, though each tag needs to be bite-sized, so let's start with just ternary
.
While "ternary" is more recognisable, this is technically called a "conditional expression" in python.
I've removed my assignment in case anyone else thinks they will get to it before me, though I may do it in the future.