Summary of alternatives:
n=42assert "-101010" == format(-n, 'b')assert "-101010" == "{0:b}".format(-n)assert "-101010" == (lambda x: x >= 0 and str(bin(x))[2:] or "-"+ str(bin(x))[3:])(-n)assert "0b101010" == bin(n)assert "101010" == bin(n)[2:] # But this won't work for negative numbers.
Contributors include John Fouhy, Tung Nguyen, mVChr, Martin Thoma. and Martijn Pieters.