Ex5 learn python the hard way

Is a format character just the character assigned to conversion types?

Could you provide a real example?

Zed says at the bottom of exercise 5 that we should “search online for all of the python format characters”. I just want to know that I am looking at the right thing. Are the format characters the “s” in “%s” or the “d” in “%d”? Here is a link to the page i found with my search… https://python-reference.readthedocs.io/en/latest/docs/str/formatting.html

Yes, that’s right. Here’s the official documentation.

2 Likes

I don’t see what you are talking about in Ex5 …
But yes if the scope is format character, I eventually think he is talking about the %d, %s which apply some conversion type to formatting.

2 Likes

Yep, that’s basically right but remember that these format characters are kind of old so they’re not too used in later version of Python.

A free service run by Zed A. Shaw for learncodethehardway.org.