[issue5675] string module requires bytes type for maketrans, but calling method on regular string does not

2009-04-02 Thread MechPaul
New submission from MechPaul : I was making a simple Caesarian cipher when this issue came up. #Following code here >>> import string >>> CAESER_SHIFT = 13 >>> TranslationTableUpper = [string.ascii_uppercase[(index + CAESER_SHIFT) % 26] for index in range(26)

[issue5749] Allow bin() to have an optional "Total Bits" argument.

2009-04-13 Thread MechPaul
New submission from MechPaul : As it stands right now, bin() only shows the minimum number of bits to display the number, however I think having a "Total Bits" argument would be very, very useful for bin(). bin(value, [Total bits to display]) "Total bits to display" is an