2009-01-04

Python has a bin

I mainly use Python on Windows as a calculator. I can use expressions, variables, and it can handle really big numbers.

When I need to transform decimals into hexadecimal I use hex(number) function. On many occasions I've tried bin(number) and failed because until Python 2.6 there was no bin function, it took me some time to realize why it worked :) then I've read Python 2.6 change log.

Python 2.6 is cooler now with the bin function!
Post a Comment