]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
bpo-28626: rearrange discussion of output formatting to encourage f-strings (GH-6036)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Mon, 9 Jul 2018 13:52:48 +0000 (06:52 -0700)
committerGitHub <noreply@github.com>
Mon, 9 Jul 2018 13:52:48 +0000 (06:52 -0700)
commit80a5f04592f7d732a541d5c35a1be1e9a6472ecb
treeb0d1215f3bdf3b743f72b4793adce0190e6420a3
parentf5197ddfd0f2c5da848af57196448810bd18bb82
bpo-28626: rearrange discussion of output formatting to encourage f-strings (GH-6036)

The 'output formatting' section of the tutorial talks a lot about manual formatting with things like .rjust() and .zfill(), with only a passing reference to 3.6's new f-strings.

This doesn't drop all of the old material, but it does rearrange the topics into a more modern order: f-strings first, discussing formatting specifiers a bit; then calling .format(); finally manual formatting with .ljust().
(cherry picked from commit ced350b1952857a9b9c68ec7e2786358bcb61050)

Co-authored-by: Andrew Kuchling <amk@amk.ca>
Doc/tutorial/inputoutput.rst