python之函数用法bin()

# -*- coding: utf-8 -*-
#python 27
#xiaodeng
#python之函数用法bin()



#bin()
#说明:一个整数转换为一个二进制字符串
'''
bin(...)
    bin(number) -> string
    
    Return the binary representation of an integer or long integer.
'''


print bin(28)#0b11100

 

posted @ 2015-11-07 16:39  Xiao|Deng  阅读(824)  评论(0编辑  收藏  举报