python_basic
文章平均质量分 60
wsdsbh
hi,你好
展开
-
第一天
Python 3.7.0b2 (v3.7.0b2:b0ef5c979b, Feb 28 2018, 02:24:20) [MSC v.1912 64 bit (AMD64)] on win32Type "copyright", "credits" or "license()" for more information.>>> >>> >>原创 2018-03-12 21:05:03 · 309 阅读 · 1 评论 -
qustions
未解决:迭代对象?必须可哈希?弱类型,强类型区块链与比特币?语言本身有分解释与编译型的吗?惰性求值?python中特有的运算符:字符串格式化?逻辑短路基于值的内存管理:???同一个值在内存中只有一份:??...原创 2018-03-12 21:08:05 · 286 阅读 · 0 评论 -
python 第二天
在 Python 中,有大量的内置模块,模块中的定义(例如:变量、函数、类)众多,不可能全部都记住,这时 dir() 函数就非常有用了。dir() 是一个内置函数,用于列出对象的所有属性及方法。在 Python 中,一切皆对象,模块也不例外,所以模块也可以使用 dir()。除了常用定义外,其它的不需要全部记住它,交给 dir() 就好了。简述dir使用 dir自定义对象版权所有:一去丶二三里,转载...原创 2018-03-13 15:27:38 · 1274 阅读 · 0 评论 -
python之str.format()
找了老半天,format()方法还是难,于是找了找str.format(*args, **kwargs)Perform a string formatting operation. The string on which this method is called can contain literal text or replacement fields delimited by braces{...原创 2018-03-19 20:25:15 · 1304 阅读 · 0 评论 -
列表
>>> x=[12,'hi']>>> x[12, 'hi']>>> x=[]>>> x[]>>> type(x)<class 'list'>>>> dir(x)['__add__', '__class__', '_原创 2018-03-21 14:39:41 · 114 阅读 · 0 评论 -
列表2
>>> x=[12,'hi']>>> x[12, 'hi']>>> x=[]>>> x[]>>> type(x)<class 'list'>>>> dir(x)['__add__', '__class__', '_原创 2018-03-21 17:13:19 · 128 阅读 · 0 评论