-1
I need to make a code that uses while
and lists, which aims the user to register an undetermined number of people while he wants and put 0 to finish and show on the screen the created list.
So I did but can’t make it stop when you type 0:
print('Digite 0 para terminar o cadastro!')
cont = 1
lista = []
n = ()
while n != 0:
n = (lista.append(input('Funcionário {}: '.format(cont))))
cont += 1
print(lista)