note 26/10/2016 basic python
2016-10-26 07:06
218 查看
1. string 可*不可/
'pom' *4 输出'pompompompom'
'pompompompom'/3 输出 error
2. round(2.5) 输出2(不是3)
3. not>and>or
4.'abc'<'bcd' 输出 error 无法比较
5.使用运算符时,记得加括号(优先级问题)
6. list.sort 不返回任何list值给memory
7. 在定义list name时,不要直接定义为list
8. TypeError: 'NoneType' object is not iterable
http://blog.csdn.net/dataspark/article/details/9953225
27/10/2016
9.巧用alist[-1]=alist[len(alist)-1]
or for i in range(0,len(alist)//2):
alist[0+i]==alist[-1-i]
10. 使用nested list前,除了创建新的list,有时要elements.append([])。否则
IndexError: list index out of range
11. hist(histtype='stepfilled')此部分决定画出的柱状图是否有黑色边界
'pom' *4 输出'pompompompom'
'pompompompom'/3 输出 error
2. round(2.5) 输出2(不是3)
3. not>and>or
4.'abc'<'bcd' 输出 error 无法比较
5.使用运算符时,记得加括号(优先级问题)
6. list.sort 不返回任何list值给memory
7. 在定义list name时,不要直接定义为list
8. TypeError: 'NoneType' object is not iterable
http://blog.csdn.net/dataspark/article/details/9953225
27/10/2016
9.巧用alist[-1]=alist[len(alist)-1]
or for i in range(0,len(alist)//2):
alist[0+i]==alist[-1-i]
10. 使用nested list前,除了创建新的list,有时要elements.append([])。否则
IndexError: list index out of range
11. hist(histtype='stepfilled')此部分决定画出的柱状图是否有黑色边界
相关文章推荐
- 2016-10-1103:26:11
- 2016 10 26考试 NOIP模拟赛 杂题
- 2016_10_26_阶段性感悟
- 欢迎来怼——第14次Scrum会议(10/26)
- 编译原理学习笔记10——(野火烧不尽再递归下降—— E → E+T | T从上向下程序)——2014_1_26
- 10-02-26 新产品
- WCF 4 Step By Step Chapter 10-12 Note (Reliable Sessions,ProgrammaticallyControlling, One-Way ...)
- 2016暑期集训10 A魏传之长坂逆袭
- Note 07/08/10 About style.grand-color and web.controls.BackColor
- Hyper-V 2016 系列教程38 在 Windows 10 上安装 Hyper-V
- 2016 10 28考试 dp 乱搞 树状数组
- hdu 5867 Water problem(2016 Multi-University Training Contest 10——水题)
- hdu 5860 Death Sequence(2016 Multi-University Training Contest 10——递推)
- 2016最新 wamp2.5+windows 10安装CoedSgniffer代码格式检查:
- 模拟赛day2 2014 10 26
- leetcode note--leetcode 26 Remove Duplicates from Sorted Array
- 我的第一个jquery插件:26+10模拟键盘
- Windows 10、Windows Server、System Center、Office 2016 Technical Preview技术预览版下载体验
- 2016/10/08 上班第一天