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) Say Hello to Python Help!

i'm having some problems in the quiz after this "Help!" video. in the "fill in the blank" question.

in the Video it gives a few ways to get help with the str function but none of them have answered the question correctly. so somebody please help me understand exactly what this question is asking?

Hi, can you post what answeres you have tried? I can then explain to you what might went wrong and make you understand it better.

3 Answers

Hello again Trever,

I understand. You was almost had it though :-).

dir() doesn't help you in explaining what a method does or how to use it. It only shows the attributes of an object like the string object.

With help(str), you are asking Python for help with the string object in general. The question states to get help for the method "center" from the string object. Therefore you have to be a little bit more explicit (like you did with the rjust method). Therefore you have to slightley modifiy the call of the help(str.rjust) method which you called.

Let me know if you got it and you are welcome!

Awesome! thank you that certainly helped me out a lot.

Great to hear! Keep it going :D

I plan to i'm going to hopefully go from this to PHP and Ruby. altho i should probably finish the opening HTML course at some point.

Great explanation Mario.

Thanks Rashaad Prince. Glad that it helped you.

Chase Kolozsy
Chase Kolozsy
976 Points

I had the same problem. It was really frustrating. I wasn't sure what the question was asking me to call help on.

help(str.what?!!!!!)

help(str)? no

help(methods)? no

help(methods.str)? no

help(str.methods)? no

help(str.help)? no

If the question was asked like this:

To get help for the method 'center' that also belongs to the str class, we would use_______

or if the question was asked like this:

To get help for the method: center, that also belongs to the str class, we would use_______

or if the question was asked like this:

To get help for the method, center, that also belongs to the str class, we would use_________

I would have immediately understood what I needed to do.

Sam Deacon
Sam Deacon
2,650 Points

poorly worded question lol, took me forever to realise it was basically asking how do I look up str.center