摘要: map() lambda set() 持续更新中 阅读全文
posted @ 2018-09-02 17:54 Kay_xs 阅读(6271) 评论(0) 推荐(2) 编辑
摘要: # for 循环实现九九乘法表for i in range(1, 10): # 控制九九乘法表的行数 for j in range(1, i+1): # 控制九九乘法表的列数 print("{}*{}={}".format(j, i, j*i), end="\t") # {}表示空位,而.format()是去填补那些空位! print() # 换行 阅读全文
posted @ 2018-09-02 17:00 Kay_xs 阅读(176) 评论(0) 推荐(0) 编辑
摘要: # while循环实现九九乘法表num_one = 1while num_one <= 9: num_two = 1 while num_two <= num_one: print("%s*%s=%s" % (num_two, num_one, num_two * num_one), end="\t") num_two += 1num_one += 1print() 阅读全文
posted @ 2018-09-02 16:51 Kay_xs 阅读(172) 评论(0) 推荐(0) 编辑
摘要: 1:在下载lxml之前,要先查看python的版本信息, 在CMD命令行输入python 再输入import pip; print(pip.pep425tags.get_supported()) 2,下载lxml模块,根据python的版本信息和操作系统 3,安装wheel:python -m pi 阅读全文
posted @ 2018-08-30 21:53 Kay_xs 阅读(3352) 评论(0) 推荐(0) 编辑
摘要: 1. 图中桌面的两个2.0.2_0文件就是xpath helper插件。 2. 进入Chrome浏览器>>>>更多工具>>>扩展程序 3. 安装成功之后,随便打开一个网站,打开xpath,输入//div,出现黄色区域证明成功 阅读全文
posted @ 2018-08-30 14:25 Kay_xs 阅读(2898) 评论(0) 推荐(0) 编辑
摘要: requests下载 英文网站 http://docs.python-requests.org/en/master/ 中文网站 http://docs.python-requests.org/zh_CN/latest/user/install.html 阅读全文
posted @ 2018-08-28 22:19 Kay_xs 阅读(415) 评论(0) 推荐(0) 编辑
摘要: 2018-08-28 22:04:51 1 .下载到桌面后解压,放到python的目录下 2 . 在CMD输入以下 F:\>cd /d F:\python\python3.5.2\Lib\requests-requests-9cfd292按回车键, 再输入F:\python\python3.5.2\ 阅读全文
posted @ 2018-08-28 22:12 Kay_xs 阅读(585) 评论(0) 推荐(0) 编辑
摘要: 两个脚本模拟远程执行命令 cmd_server.py cmd_client.py 阅读全文
posted @ 2018-08-26 22:42 Kay_xs 阅读(593) 评论(0) 推荐(0) 编辑
摘要: 恢复内容开始 优化两个小脚本实现不间断聊天: server.py: client.py: 恢复内容结束 阅读全文
posted @ 2018-08-26 22:08 Kay_xs 阅读(326) 评论(0) 推荐(0) 编辑
摘要: 编写两个小脚本实现聊天功能0.1: 脚本一,服务器端:server.py 脚本二,客户端:client.py 阅读全文
posted @ 2018-08-24 13:46 Kay_xs 阅读(3685) 评论(0) 推荐(0) 编辑