python272
A. python列表题
思路就以学分为key ,语文 数学 英语 分别为value构造三个字典 以key查找value 然后输出结果
list1 = [1, 2, 3, 4]
list2 = [98, 67, 89, 80]
list3 = [100, 90, 83, 62]
list4 = [90, 98, 100, 82]
dic1 = dict(zip(list1, list2))
dic2 = dict(zip(list1, list3))
dic3 = dict(zip(list1, list4))
key = int(input('请输入学生学号:'))
# 判断学生学号是否存在
if key in list1:
# 语文
language = int(dic1[key])
# 数学
mathematics = int(dic2[key])
# 英语
english = int(dic3[key])
# 总和
total = language + mathematics + english
print('语文:' + str(language) + ' 数学:' + str(mathematics) + ' 英语:' + str(english) + ' 总分:' + str(total))
B. Python语言怎么学急~~~可以给分~~
python国内已经有很多中文书籍了, 在各大书店都买得到, 个人推荐去卓越网买, 有打折还免邮费, 上门付款服务超好.
我买过本 <征服python>, 很入门, 还不错, 网上也有很多电子书可以看, 网上还有一本叫做Dive into Python的, 有中文版, 个人认为很不错.
国内最大的python讨论组应该是google的python邮件列表, http://python.cn/ 从这里可以进, 有问题可以进去问.
以下是个人收藏, 多数是e文的.
<wxpython in action>
pdf
http://www.namipan.com/d/
<Tkinter reference>
pdf
http://www.namipan.com/d/
<Wrox Beginning Python>
pdf
http://www.namipan.com/d/
<The omniORBpy Users Guide>
pdf
http://www.namipan.com/d/
<Thinking in python>
chm
http://www.namipan.com/d/
<swig Python>
pdf
http://www.namipan.com/d/
<Teach Your self Python In 24 Hours>
html
http://www.namipan.com/d/
<Python Windows Tutorial>
doc
http://www.namipan.com/d/
<Python学习笔记>
pdf
http://www.namipan.com/d/
<python-numical>
pdf
http://www.namipan.com/d/
<Python Visual Quickstart Guide>
chm
http://www.namipan.com/d/
<python wdsl>
pdf
http://www.namipan.com/d/
<Python Programming with the JavaT Class Libraries>
chm
http://www.namipan.com/d/
<Python Guide>
html
http://www.namipan.com/d/
<python_essencial_ref>
html
http://www.namipan.com/d/
<Python Programming for the Absolute Beginner>
chm
http://www.namipan.com/d/
<Prentice Hall Rapid Web Applications with TurboGears>
chm
http://www.namipan.com/d/
<Python Gist Graphics Manual>
pdf
http://www.namipan.com/d/
<Python course in Bioinformatics>
pdf
http://www.namipan.com/d/
<Python 2.1 Bible>
pdf
http://www.namipan.com/d/
<Data Structures And Algorithms With Object-Oriented Design Patterns In Python>
chm
http://www.namipan.com/d/
<Data Structures and Algorithms with Object-Oriented Design Patterns in Python (2004)>
chm
http://www.namipan.com/d/
<pygtk2-tut>
pdf
http://www.namipan.com/d/
<programming python>
pdf
http://www.namipan.com/d/
<OReilly - Programming Python 2nd Ed>
chm
http://www.namipan.com/d/
<OReilly - Programming Python_ 3rd Edition (2006)>
chm
http://www.namipan.com/d/
<pil handbook>
pdf
http://www.namipan.com/d/
<Premier Press Game Programming with Python Lua and Ruby>
chm
http://www.namipan.com/d/
<Game.Programming.with.Python.Lua.And.Ruby>
pdf
http://www.namipan.com/d/
<Python Guide - For Beginners>
html
http://www.namipan.com/d/
<OReilly.Python.in.a.Nutshell.2nd.Edition>
chm
http://www.namipan.com/d/
<OReilly - Python Programming on Win32>
chm
http://www.namipan.com/d/
<Oreilly.Learning.Python.2nd.Edition>
chm
http://www.namipan.com/d/
<Oreilly Python Cookbook 2Nd Edition>
chm
http://www.namipan.com/d/
<GUI Programming with Python>
html
http://www.namipan.com/d/
<OReilly - Learning Python>
chm
http://www.namipan.com/d/
<OReilly - Python Cookbook>
chm
http://www.namipan.com/d/
<OReilly - Python Standard Library>
chm
http://www.namipan.com/d/
<OReilly - Python Pocket Reference_ 2nd Ed>
chm
http://www.namipan.com/d/
<OReilly - Python In A Nutshell>
chm
http://www.namipan.com/d/
<OReilly - Python And Xml>
pdf
http://www.namipan.com/d/
<OReilly - Core Python Programming>
pdf
http://www.namipan.com/d/
<Non-Programmers Tutorial For Python>
pdf
http://www.namipan.com/d/
<New Riders - Jython for Java Programmers>
chm
http://www.namipan.com/d/
<How_To_Think_Like_A_Computer_Scientist-Learning_With_Python-2002>
pdf
http://www.namipan.com/d/
<GUI Programming with Python - QT Edition>
chm
http://www.namipan.com/d/
<Dive into Python>
<CUP_.Numerical.Methods.in.Engineering.with.Python.(2005)>
pdf
http://www.namipan.com/d/
<Core_Python_Programming_Wesley J. Chun_(Prentice Hall PTR)>
pdf
http://www.namipan.com/d/
C. 《Python数据分析基础》epub下载在线阅读,求百度网盘云资源
《Python数据分析基础》([美] Clinton W. Brownley)电子书网盘下载免费在线阅读
链接:https://pan..com/s/1GWFNN0m7_eQEaCGVkH1isA
书名:Python数据分析基础
作者:[美] Clinton W. Brownley
译者:陈光欣
豆瓣评分:7.0
出版社:人民邮电出版社
出版年份:2017-8
页数:272
内容简介:
想深入应用手中的数据?还是想在上千份文件上重复同样的分析过程?没有编程经验的非程序员们如何能在最短的时间内学会用当今炙手可热的Python语言进行数据分析?
来自Facebook的数据专家Clinton Brownley可以帮您解决上述问题。在他的这本书里,读者将能掌握基本Python编程方法,学会编写出处理电子表格和数据库中的数据的脚本,并了解使用Python模块来解析文件、分组数据和生成统计量的方法。
学习基础语法,创建并运行自己的Python脚本
读取和解析CSV文件
读取多个Excel工作表和工作簿
执行数据库操作
搜索特定记录、分组数据和解析文本文件
建立统计图并绘图
生成描述性统计量并估计回归模型和分类模型
在Windows和Mac环境下按计划自动运行脚本
作者简介:
Clinton W. Brownley
博士,Facebook数据科学家,负责大数据流水线、统计建模和数据可视化项目,并为大型基础设施建设提供数据驱动的决策建议。
D. python 字符串分割split()函数中中英文逗号分割
在我这里没有问题啊,能够正确地分割。注意最好不要用内置函数名称作为变量名。
E. python正则表达式如何匹配这种格式,并把数字一对一对取出来
importre
s='(272,252)(79,168)'
pattern=re.compile('((d+),(d+))')
printpattern.findall(s)
#[('272','252'),('79','168')]
F. Ubuntu安装的python2.7使用项目脚本启动报了下面的错
python 内部有一个模块叫stat.py
如果自己也定义一个同名的模块,就会出现上述错误。。。
修正方法: 把自己的模块改个名字。。。。
G. python 2.7 IDLE打不开
这种情况的话,
1,可能是你没有添加环境变量吧。
在我的电脑右击==》属性==》高级==》环境变量==》系统变量==》path中添加 ;C:\Python27
2,确定一下C:\Python27\Lib\idlelib\中有无idel.py这个文件。
如果没有那就重新安装一遍吧。
H. Python 2.7.12 安装pypng报错。
朋友 这个不是错误。 错误提示在最上边,顺便看一下pypng的依赖是什么。装好依赖,再装pypng