Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- type_of_gas = input(str())
- liters = float(input())
- if type_of_gas == 'Diesel':
- if liters >= 25:
- print(f'You have enough diesel.')
- else:
- print(f'Fill your tank with diesel!')
- elif type_of_gas == 'Gasoline':
- if liters >= 25:
- print(f'You have enough gasoline.')
- else:
- print(f'Fill your tank with gasoline!')
- elif type_of_gas == 'Gas':
- if liters >= 25:
- print(f'You have enough gas.')
- else:
- print(f'Fill your tank with gas!')
- else:
- print('Invalid fuel!')
Advertisement
Add Comment
Please, Sign In to add comment