上一页 1 ··· 26 27 28 29 30 31 32 33 34 ··· 42 下一页
摘要: 一、安装依赖包 yum install -y gcc gcc-gfortran glibc-headers readline-devel libXt-devel gcc-c++ xz-devel.x86_64 texinfo.x86_64 texlive-pdftex-doc.noarch (此依赖 阅读全文
posted @ 2018-07-30 13:10 Presley 阅读(529) 评论(0) 推荐(0) 编辑
摘要: 转自:https://blog.csdn.net/u014062332/article/details/52911405 启动docker web服务时 虚拟机端口转发 外部无法访问 centos 7 docker 启动了一个web服务 但是启动时 报 WARNING: IPv4 forwardin 阅读全文
posted @ 2018-07-30 09:45 Presley 阅读(519) 评论(0) 推荐(0) 编辑
摘要: 一、json,用于字符串和Python数据类型间进行转换(适用于所有语言) 1、Json模块提供了四个功能:dumps 、 dump、loads、load 二、pickle,用于python特有的类型和python的数据类型间进行转换(只适用于python) 1、pickle模块提供了四个功能:du 阅读全文
posted @ 2018-07-29 09:05 Presley 阅读(205) 评论(0) 推荐(0) 编辑
摘要: 一、打印相对路径 print(__file__) 二、打印绝对路径 import os print(os.path.abspath(__file__)) 三、打印文件名 import os print(os.path.dirname(os.path.abspath(__file__))) 阅读全文
posted @ 2018-07-28 22:44 Presley 阅读(8528) 评论(0) 推荐(0) 编辑
摘要: 一、模块:用一坨代码实现了某个功能的代码集合。 二、模块分为三种 1、自定义模块 2、内置标准模块(又称标准库) 3、开源模块(上传方式,百度PyPi) 开源模块安装方式: a、yum b、pip c、apt-get d、下载源码,然后解压,然后进入目录,然后编译安装: python setup.p 阅读全文
posted @ 2018-07-28 12:23 Presley 阅读(148) 评论(0) 推荐(0) 编辑
摘要: 引用自:https://www.cnblogs.com/sch01ar/p/8552295.html 阅读全文
posted @ 2018-07-28 09:09 Presley 阅读(147) 评论(0) 推荐(0) 编辑
摘要: 1 #!/usr/bin/env python 2 #-*- coding:utf-8 -*- 3 data = [10,4,33,21,54,3,8,11,5,22,2,1,17,13,6] 4 5 for j in range(1,len(data)): 6 for i in range(len 阅读全文
posted @ 2018-07-26 21:36 Presley 阅读(164) 评论(0) 推荐(0) 编辑
摘要: 一、-e 和 -N /usr/local/bin/mysql -h127.0.0.1 -uroot -pxxxx -N -e "use abc; show tables;" -e 后面跟上要执行的SQL语句 -N 参数是不显示表头 阅读全文
posted @ 2018-07-25 16:49 Presley 阅读(4014) 评论(0) 推荐(0) 编辑
摘要: 一、上面的第二行和第三行也可以合并成一行来写 m = p.match("^[0-9]",'13435aSAdb') 效果是一样的,区别在于第一种方式是提前对要匹配的格式进行编译,第二种简写是每次匹配的时候都要进行一次匹配公式的编译,加入你需要从一个5w行的文件中匹配出所有以数字开头的行建议先把正则公 阅读全文
posted @ 2018-07-23 21:36 Presley 阅读(198) 评论(0) 推荐(0) 编辑
摘要: groupadd mysql #创建mysql分组 useradd -M(不创建主目录) -s(不允许登录) /sbin/nologin mysql -g(加入mysql组) mysql 阅读全文
posted @ 2018-07-20 17:18 Presley 阅读(3287) 评论(0) 推荐(0) 编辑
上一页 1 ··· 26 27 28 29 30 31 32 33 34 ··· 42 下一页