micropython/tests/basics/builtin_ord.py

10 wiersze
132 B
Python

# test builtin ord (whether or not we support unicode)
print(ord('a'))
try:
ord('')
except TypeError:
print("TypeError")