随笔分类 -  python

摘要:pylint是一个不错的代码静态检查工具。将其配置在pycharm中,随时对代码进行分析,确保所有代码都符合pep8规范,以便于养成良好的习惯,将来受用无穷:)。 配置 一张截图说明所有的配置。如下: 使用 参数说明 --init-hook "import sys;sys.path.append(' 阅读全文
posted @ 2020-01-03 18:11 一尾 阅读(601) 评论(0) 推荐(0) 编辑
摘要:使用 pip 安装软件时,使用国内镜像可以大大提高下载速度 常用国内镜像 https://pypi.tuna.tsinghua.edu.cn/simple/ # 清华大学 https://mirrors.aliyun.com/pypi/simple/ # 阿里云 https://pypi.douba 阅读全文
posted @ 2019-11-27 16:47 一尾 阅读(235) 评论(0) 推荐(0) 编辑
摘要:lst = ["bob","jack","马云","马化腾","王健林"] del lst[1:3] print(lst) 一、列表索引和切片 lst = ["移动硬盘", "手机", 110, True, False, ["人民币", "美金", '欧元']] lst = ["海上钢琴师", "奥 阅读全文
posted @ 2019-11-20 17:41 一尾 阅读(190) 评论(0) 推荐(0) 编辑
摘要:一、创建字符串 使用 '' , "" , ''' 和 """ 来创建字符串 var1 = 'hello, world' var2 = "jack" 二、索引和切片 (1)索引 s = "伊丽莎白鼠"print(s[0])print(s[1])print(s[2])print(s[3])print(s 阅读全文
posted @ 2019-11-20 16:29 一尾 阅读(139) 评论(0) 推荐(0) 编辑
摘要:python自定义函数中有两种不定长参数, 第一种是*name:加了星号 * 的参数会以元组(tuple)的形式导入 第二种是**name:加了星号 * *的参数会以字典(dict)的形式导入 *name形式: def add(a, b, *args): print(a) print(b) prin 阅读全文
posted @ 2019-10-25 16:42 一尾 阅读(218) 评论(0) 推荐(0) 编辑
摘要:一、注释 单行注释 #打印“hello world” print("hello.world!") 另外一种单行注释 print("hello,world!") #打印hello,world 多行注释 ''' print("l love u") print("china") ''' 二、算术运算符 操 阅读全文
posted @ 2019-10-21 14:43 一尾 阅读(214) 评论(0) 推荐(0) 编辑
摘要:一、进入需要共享的文件目录 #cd /home #python -m SimpleHTTPServer 二、浏览器访问资源 再浏览器地址栏输入: 服务器IP:8000 如图: 阅读全文
posted @ 2019-09-25 17:40 一尾 阅读(364) 评论(0) 推荐(0) 编辑
摘要:1 Web应用 https://www.cnblogs.com/yuanchenqi/articles/8869302.html2 http协议 https://www.cnblogs.com/yuanchenqi/articles/8875623.html3 web框架 https://www.c 阅读全文
posted @ 2019-09-25 17:32 一尾 阅读(121) 评论(0) 推荐(0) 编辑
摘要:[转]:https://www.centos.bz/2018/05/centos-7-4-%e5%ae%89%e8%a3%85python3%e5%8f%8a%e8%99%9a%e6%8b%9f%e7%8e%af%e5%a2%83/#5.%20%E5%88%9B%E5%BB%BA%E8%BD%AF% 阅读全文
posted @ 2019-08-28 16:16 一尾 阅读(559) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示