Exemplo Código de While Loop em Python
total = 0
num = int(input("Enter the number: "))
while num != 7:
total = total+num
num = int(input("Enter the number: "))
print("Sum: ", total)
Outrageous Ostrich