Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialali baba
476 Pointswhats wrong with my code? it is only adding one item in the list
make a list to hold on to our items
shopping_list = []
print out insturctions on How to use use the app
print("what should we pick at the store?") print("Enter 'DONE' to stop adding things")
while True: #ask for new items new_item = input("> ")
if new_item == 'DONE': break
#add new items to our list shopping_list.append(new_item)
# be able to quit the app # print out the list print("here is your list")
for item in shopping_list: print(item)
1 Answer
Milosh Stanimirovic
1,945 PointsI ran it and it work no errors. It should give you error if you can post that it would help.
Marcus Yow
12,929 PointsMarcus Yow
12,929 PointsWell I just ran your code and it worked. Just check to make sure you don't have any syntax errors and that your code is properly indented.