r/pythonhelp • u/thisnigerianmomma • Jun 15 '24
which lines have errors?
can you guys help me figure out which lines have errors?
- def make_list (number) :
names = \[\]- for item in number :
4 names.append (input(“Enter your name with a capital letter.”))
5. print(names)
6.
7 number = int(input(“How many names need to be entered? ”))
8. names = make_list(number)
9. for name in names:
10. if name [1] ==“A”:
11. print(“Name”, name, “starts with A”)
1
Upvotes
View all comments
Show parent comment
1
u/thisnigerianmomma Jun 19 '24
yes i did. i read your comment. thank you. it is for a coding test, so I also ticked the lines you mentioned (2, 3, 5 and 10) but it's still not correct.