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 trialjamie Macdiarmid
2,048 PointsStuck again
It can become gobbledegook when you stare and think about it long enough. Is there a way to get the answers without having to bother people. Can I recomend that Treehouse puts a Timer on the solution e.g if after 10 mins your stuck a solution will appear.
what is the correct answer?
def printer(count):
print("Hi * {} ".format(2))
1 Answer
Haider Ali
Python Development Techdegree Graduate 24,728 PointsHi Jamie, here is the solution to the challenge:
def printer(count): #you got this part right
print('Hi' * count) #now all you have to do is print 'Hi' as many times as the count argument
#you can do this by using the multiplication operator: *
Wade Wilson
3,505 PointsWade Wilson
3,505 PointsThank you, I had it as this...
I guess it just isn't fully clicking with me that i had include the name of the argument i created. That has been happening a lot this last week while learning python.
jamie Macdiarmid
2,048 Pointsjamie Macdiarmid
2,048 PointsThanks Haider. Think I over complicated it.