1
I am unable to perform the following exercise in python:
João Papo-de-Pescador, a good man, bought a microcomputer to control the daily income of his work. Every time he brings a weight of fish greater than that established by the fishing regulation of the state of São Paulo (50 kilos) must pay a fine of R $ 4,00 per kilo surplus. João needs you to do a program that reads the weight variable (fish weight) and calculates the excess. Write in the variable excess the amount of kilos beyond the limit and the variable fine the amount of the fine that John should pay. Print program data with appropriate messages.
Here’s what I tried:
pesos = input('Digite o numero de quilos q vc pegou:')
if pesos > 50:
pesos -= 50
excesso = pesos
multa = excesso * 4
print 'Total da multa: ' + str(multa)
else:
print 'Não teve excesso'
– Victor Stafusa
And thanks bro I’ll do it
– twdnl14
Victor has a way to fix my program? I think I did something wrong
– twdnl14
Put it here. Edit the question.
– Rafael Barros
ok put there
– twdnl14