Skip to content
Snippets Groups Projects
Commit a4f96c8c authored by Damien George's avatar Damien George
Browse files

tests/basics: Add tests for if-expressions.

parent a31a3a9f
No related branches found
No related tags found
No related merge requests found
# test if-expressions
print(1 if 0 else 2)
print(3 if 1 else 4)
def f(x):
print('a' if x else 'b')
f([])
f([1])
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment