Working on a list creator to generate assignments for a sound crew. Creating 4 lists and adding people to the various lists based on the training they have recieved and the jobs they are capable of doing. I have one base list with all of the people included. The .append works for that list, but for all lists with conditions the names are not appending.
I tried changing my for from for str in addto to other things but nothing has worked so far.
my_list = []
stage_list = []
mic_list = []
all_list = []
def addto_list():
addto = input()
for str in addto:
input("Can he do stage?(y/n): ")
if input == "y":
stage_list.append(addto)
else:
break
for str in addto:
input("Can he do mic?(y/n): ")
if input == "y":
mic_list.append(addto)
else:
break
for str in addto:
input("Can he do sound?(y/n): ")
if input == "y":
all_list.append(addto)
else:
break
my_list.append(addto)
The results I want are when I answer y for any of the conditional statements then the name append to the list. But when I do that the list still appears blank. For example I run the code
addto_list()
Input: Jack
Can he do stage: y
can he do mic: y
can he do sound: y
print(my_list)
return: Jack
print(mic_list)
return: [] blank when it should say Jack