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![](https://ecs-static.teamtreehouse.com/assets/views/marketing/shared/community-banner-white-47072046c51352fe6a69f5e691ff5700b28bb11d45197d7bdf066d9ea3f72d0c.webp)
![Georgios Vivilakis](https://uploads.teamtreehouse.com/production/profile-photos/11719116/micro_50838254773_a868fcd01a_oCROP.webp)
Georgios Vivilakis
Python Development Techdegree Student 3,020 Pointssquaring cant give me an answer. I'm confused!
def square(number): return (number * number) result = square(25) print(result)
def square(number):
square = 100
return (number * number)
result = square(10)
print(result)
1 Answer
![Travis Alstrand](https://uploads.teamtreehouse.com/production/profile-photos/11658224/micro_travis.jpg)
Travis Alstrand
Data Analysis Techdegree Graduate 49,407 PointsHey Georgios Vivilakis !
You're very close here! Your provided code snippet passes the first task in the Challenge, but for the second, notice it's asking to pass the argument of 3
and you're currently passing 10
.
We don't need the print()
statement either, that can sometimes throw things off in these challenges.
Also, the square
variable inside of your function isn't currently being used, so we can remove that.
I hope this helps!
def square(number):
return (number * number)
result = square(3)
Georgios Vivilakis
Python Development Techdegree Student 3,020 PointsGeorgios Vivilakis
Python Development Techdegree Student 3,020 PointsOh man, it was right around the corner haha! I definitely got overthinking this :)