
PYTHON
蒙虒
抓住最后的稻草
展开
-
centos7 安装 python3.7 与 python2 共存
1、安装依赖包# yum install zlib-devel bzip2-devel openssl-devel ncurses-devel sqlite-devel readline-devel tk-devel gcc make# yum install "Development tools"2、安装wget 命令yum -yinstallwget3、下载编译包...原创 2019-11-14 17:06:11 · 203 阅读 · 0 评论 -
python下划线开头的标识符的特殊意义
单下划线、双下划线、头尾双下划线说明:__foo__: 定义的是特殊方法,一般是系统定义名字 ,类似__init__()之类的。 _foo: 以单下划线开头的表示的是 protected 类型的变量,即保护类型只能允许其本身与子类进行访问,不能用于from module import * __foo: 双下划线的表示的是私有类型(private)的变量, 只能是允许这个类本身进行访问...原创 2019-11-14 16:57:48 · 1489 阅读 · 0 评论 -
更改pip源至清华、阿里镜像
可以在使用pip的时候加参数-ihttps://pypi.tuna.tsinghua.edu.cn/simple例如:pip install -ihttps://pypi.tuna.tsinghua.edu.cn/simplegevent,这样就会从清华这边的镜像去安装gevent库。阿里源地址为:https://mirrors.aliyun.com/pypi/sim...原创 2019-11-14 16:51:22 · 170 阅读 · 0 评论