micropython/tests/basics/return1.py

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

14 lines
144 B
Python
Raw Normal View History

# test return statement
def f():
return
print(f())
def g():
return 1
print(g())
def f(x):
return 1 if x else 2
print(f(0), f(1))