a = 0 if random.random() < 0.5 else 1
in love with python’s take on the ternary operator…
1 Notes/ Hide
-
dstrelau reblogged this from philadamsdotnet and added:
The first time I tried to use a ternary...Python, I typed the traditional cond ? if : else...
-
philadamsdotnet posted this