2
I want to run this very simple loop:
for i in range (1, 5):
num = int(input("Digite um numero positivo: "))
if (num < 0):
print("Você digitou um número negativo, tente de novo.")
If the user enters a negative number, I want this "guess" not to be added to the counter i, that is, I want to subtract 1 from i so that the guess is not accounted for.
I’ve tried to put i = i -1 below my if but this does not change the value of i of my accountant.
Thank you very much solved my problem.
– doretox