Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions Doc/tutorial/inputoutput.rst
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,8 @@ printing space-separated values. There are several ways to format output.
::

>>> yes_votes = 42_572_654 ; no_votes = 43_132_495
>>> percentage = (yes_votes/(yes_votes+no_votes)
>>> '{:-9} YES votes {:2.2%}'.format(yes_votes, percentage))
>>> percentage = yes_votes/(yes_votes+no_votes)
>>> '{:-9} YES votes {:2.2%}'.format(yes_votes, percentage)
' 42572654 YES votes 49.67%'

* Finally, you can do all the string handling yourself by using string slicing and
Expand Down