Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- while True:
- x = (input('First number:'''))
- y = (input('Second number:'''))
- arithmetic = (input('Choose operation:'''))
- if arithmetic =="+":
- print('{} + {} = '.format(x, y), end='')
- print(int(x)+int(y))
- elif arithmetic == '-':
- print('{} - {} = '.format(x, y), end='')
- print(int(x)-int(y))
- elif arithmetic == '/':
- print('{} / {} = '.format(x, y), end='')
- print(int(x)/int(y))
- else:
- print('Неизвестная операция')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement