RosettaCodeData/Task/Sort-three-variables/Python/sort-three-variables-2.py

6 lines
205 B
Python
Raw Permalink Normal View History

2023-07-01 11:58:00 -04:00
while True:
x, y, z = eval(input('Three Python values: '))
print(f'As read: x = {x!r}; y = {y!r}; z = {z!r}')
x, y, z = sorted((x, y, z))
print(f' Sorted: x = {x!r}; y = {y!r}; z = {z!r}')