Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- number = float(input())
- input_unit = input()
- output_unit = input()
- if input_unit == "cm":
- number *= 10
- elif input_unit== "m":
- number *= 1000
- if output_unit == "cm":
- number /= 10
- elif output_unit == "m":
- number /= 1000
- print(f'{number:.3f}')
Add Comment
Please, Sign In to add comment