Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- width = int(input())
- lenght = int(input())
- height = int(input())
- free_space = True
- total_free_space = width * lenght * height
- command = input()
- while command != 'Done':
- box_num = int(command)
- total_free_space -= box_num
- if total_free_space < 0:
- free_space = False
- break
- command = input()
- if free_space:
- print(f'{total_free_space} Cubic meters left.')
- else:
- print(f'No more free space! You need {abs(total_free_space)} Cubic meters more.')
Advertisement
Add Comment
Please, Sign In to add comment