TOPIC

Runtime Error - Alguem poderia ajudar?

Mario Queiroz asked 10 months ago

qtdP = 1

cont = 0

while(qtdP>0): qtdP = int(input())

lista = [qtdP]

lista = list(map(int,input().split()))

for i in range(qtdP):

 if(i > 0 and lista[i] - lista[i-1]<10):

    j = lista[i]-lista[i-1]

    cont = cont + j

 else:

    cont = cont + 10

print(cont)

cont = 0

This topic has not been answered yet. Be the first!

Remember not post solutions. Your post may be reviewed by our moderators.