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 trial

Python Python Basics (Retired) Putting the "Fun" Back in "Function" Functions

Why do I keep getting a message saying "Oops! It looks like Task 1 is no longer passing."?

I passed the first part, but now I keep getting that message on the second part. I compared my response to some of the others in forums, and I can't figure out what I'm doing wrong.

functions.py
# add_list([1, 2, 3]) should return 6
# summarize([1, 2, 3]) should return "The sum of [1, 2, 3] is 6."
# Note: both functions will only take *one* argument each.
def add_list(items):
  total = 0
  for item in items:
    total = total + item
  return total


def summarize(listed_items)
  return "The sum of {} is {}.".format(listed_items, add_list(listed_items))

summarize([1, 2, 3])

1 Answer

Chase Marchione
Chase Marchione
155,055 Points

Hi Whitney,

Looks like the lack of a colon (:) at the end of the summarize function's header (to tell the compiler that your header is done) threw it off.

def summarize(listed_items):

Hope this helps!

ah crud...it's always the little things. thanks, man.