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 trialPeter Braswell
Courses Plus Student 1,507 PointsProbably missing something obvious on the challenge, but ...
I've tried running this code in a workspace and it works just fine. Am I missing something in terms of the set-up or completion requirement?
def loopy(items):
for item in items:
print item
2 Answers
Stuart Wright
41,120 Pointsprint() is a function so the parameters passed to it (item in this case) should be in parentheses:
def loopy(items):
for item in items:
print(item)
Peter Braswell
Courses Plus Student 1,507 PointsDang! I feel dumb! :)
Yep, that was it! Too much Ruby programming!
Nicholas Grenwalt
46,626 PointsDon't feel dumb. I once misspelled a word in a project and overlooked the misspelling for like hours thinking it had to be a something more complicated. ;) Coding has a way of humbling us all. Just keep at it.
Greg Kaleka
39,021 PointsAnother reason not to feel dumb: that's actually the way print
works in python 2. Treehouse used Python 3, which now uses print
as a function.