Welcome to the Treehouse Community
The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.
ONCE AGAIN i am being asked to do something i am not sure how to do. It was not covered in the video and now i need to do some extra stuff like 'append(val)' whatever that means.
my_list =  for i in my_list.append(val): print(i)
Chris FreemanTreehouse Moderator 67,779 Points
It is the
val reference that is causing the
# in evaluating the statement for i in my_list.append(val): # The reference my_list.append(val) # is evaluated first
val was defined, the append method does not return a value so the
for loop would not run. The correct form would be:
for i in my_list:
Post back if you need more help. Good luck!!!