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 Collections (2016, retired 2019) Tuples Packing

mourad marzouk
mourad marzouk
5,560 Points

confused at the wording.

I really don't understand what this challenge task is asking, can someone please explain what this asking or can you please reword the prompt.

1 Answer

Steven Parker
Steven Parker
229,608 Points

Try breaking it down:

Let's play with the *args pattern. :point_left: this is a clue that you'll be using the packing operator (asterisk)
Create a function named multiply:point_left: define a function named "multiply"
that takes any number of arguments. :point_left: use the packing ("splat") operator in the argument
Return the product (multiplied value) :point_left: so you'll be multiplying things together
of all of the supplied arguments. :point_left: you may want a loop to do them all
Slices might come in handy for this one. :point_left: ignore this unless it inspires you to do something with slices

You might also try looking at some of the other questions on this same challenge. Just be aware that any code in them is likely to contain errors.