#
ternary op
Ternary operator is a short hand if...else
.
PocketPy supports C style ternary.
#
Syntax
<condition> ? <if_true> : <if_false>
#
Example
a = 1
s = a == 1 ? "a is 1" : "a is not 1"
print(s) # a is 1
Python style ternary is not supported yet in PocketPy.