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

I have no idea what your are asking in this challenge task. Please be more specific or at least have previous lectures

that addressed this challenge

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 eac

def add_list([1,2,3]):

1 Answer

Hi Jeff

The first part of the challenge asks you to create a function that will take a list as an argument and return a total of the numbers in the list so for example if the list was [1,2,3] your function should return 6 and so on.

The second part of the challenge asks you to create a function called summarize that will also take a list as an argument and return a string like so "The sum of X is Y" where X will be the passed in list to the summarize function and Y the total of the passed in list. You can make use of the add_list function to get the total.

hope this helps in understanding what the challenge is asking of you.