[New-bugs-announce] [issue14694] Option to show leading zeros for bin/hex/oct
report at bugs.python.org
Sun Apr 29 18:12:15 CEST 2012
New submission from endolith <endolith at gmail.com>:
Suggestion: Add an option to bin/hex/oct functions to format binary output with a minimum fixed width, including leading zeros. Also might be useful for hex and oct.
Currently, bin(18) produces '0b10010'
with this change, something like bin(18, foo=8) would produce '0b00010010'
Examples of people wanting this:
components: Interpreter Core
title: Option to show leading zeros for bin/hex/oct
versions: Python 2.7
Python tracker <report at bugs.python.org>
More information about the New-bugs-announce