Re: help in obtaining binary equivalent of a decimal number in python

2013-05-23 Thread Dave Angel
On 05/23/2013 07:30 AM, lokeshkopp...@gmail.com wrote: i need to get 32 bit binary equivalent of a decimal and need to change the 0's to 1's and 1's to 0's For Example if the input is 2 Output should be: the 32bit equivalent of 2 : 0010 and the 1's compliment is

Re: help in obtaining binary equivalent of a decimal number in python

2013-05-23 Thread Chris Angelico
On Thu, May 23, 2013 at 9:30 PM, wrote: > i need to get 32 bit binary equivalent of a decimal and need to change the > 0's to 1's and 1's to 0's > For Example > if the input is 2 > Output should be: > the 32bit equivalent of 2 : 0010 > and the 1's compliment is:

help in obtaining binary equivalent of a decimal number in python

2013-05-23 Thread lokeshkoppaka
i need to get 32 bit binary equivalent of a decimal and need to change the 0's to 1's and 1's to 0's For Example if the input is 2 Output should be: the 32bit equivalent of 2 : 0010 and the 1's compliment is: 1101 is there any