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 trialIsrael Mabhoo
16,356 PointsCreate a function named area() that takes a single argument which will be a two-member tuple. area() should return the r
Create a function named area() that takes a single argument which will be a two-member tuple. area() should return the result of multiplying the first item in the tuple by the second item in the tuple.
1 Answer
Ines FazliΔ
Python Web Development Techdegree Student 9,569 PointsHi, you just make a function and then in it make a new variable...you can call it result for instance and in it you multiply items in a tuple..you can do that by indexing them. and then return variable(result). that way the tuple stays intact and you get your result.
Jake Kobs
9,215 PointsJake Kobs
9,215 PointsDo they mean this?: