上一页 1 ··· 3 4 5 6 7 8 下一页

2019年9月5日

1.4 python 类型转换函数

摘要: 函数 描述 int(x [,base]) 将X转换为一个整数 float(x) 将x转换为一个浮点数 complex(real [,imag]) 创建一个复数 str(x) 将对象x转换为字符串 repr(x) 将对象x转换为表达式字符串 eval(str) 用例计算在字符串中的有效python表达 阅读全文

posted @ 2019-09-05 15:58 Helianthus720 阅读(137) 评论(0) 推荐(0) 编辑

1.3 python数据类型之三

摘要: Set(集合) 基本功能是进行成员关系测试和删除重复元素 使用{ } 或者 set() 函数进行创建;创建空集合必须使用set() >>>studengt = {'Amy','Tom','Jim'} >>>a = set('abcdef') Dictionary(字典) 字典是一种映射类型,用{ } 阅读全文

posted @ 2019-09-05 14:27 Helianthus720 阅读(93) 评论(0) 推荐(0) 编辑

1.2 python数据类型之二

摘要: List(列表) list写在方括号[ ] 之间,用逗号分隔 list中的元素类型可以不相同,支持Number,string ,甚至可以包含list a list截取 b list截取可以接收第三个参数,作用是截取的步长(还不能理解) 如第三个参数为负数,表示逆向读取 >>>input1=[1,2, 阅读全文

posted @ 2019-09-05 14:17 Helianthus720 阅读(152) 评论(0) 推荐(0) 编辑

1.1 Python数据类型之一

摘要: **本次学习主要已Python3为主 六个标准数据类型:Number,String,List,Tuple,Set,Dictionary 不可变数据:Number,String,Tuple 可变数据:List,Set,Dictionary Number(数字) 支持 int,float,bool,co 阅读全文

posted @ 2019-09-05 11:00 Helianthus720 阅读(129) 评论(0) 推荐(0) 编辑

2019年9月2日

liunx 查看某个端口连接数

摘要: netstat -ant|grep "端口号" | wc -l 阅读全文

posted @ 2019-09-02 15:31 Helianthus720 阅读(131) 评论(0) 推荐(0) 编辑

2019年8月29日

liunx 统计文件夹下文件个数

摘要: 当前文件夹下所有文件个数: ls -l | grep "^-"| wc -l 当前文件夹下目录个数: ls -l | grep "^d"| wc -l 当前文件夹下文件以及子目录文件个数:ls -lR | grep "^-"| wc -l 当前文件夹下目录以及子文件夹下目录个数:ls -lR | g 阅读全文

posted @ 2019-08-29 10:24 Helianthus720 阅读(132) 评论(0) 推荐(0) 编辑

liunx 下 redis 日志文件路径

摘要: 可查看redis.conf下的logfile(因文件中有多个logfile,找到前面有loglevel的就是) ,如下图 阅读全文

posted @ 2019-08-29 10:06 Helianthus720 阅读(10319) 评论(0) 推荐(0) 编辑

Redis is configured to save RDB snapshots, but is currently not able to persist on disk. Commands that may modify the data set are disabled

摘要: 在redis上删除key值时,出现: Redis is configured to save RDB snapshots, but is currently not able to persist on disk. Commands that may modify the data set are 阅读全文

posted @ 2019-08-29 09:55 Helianthus720 阅读(666) 评论(0) 推荐(0) 编辑

2019年8月23日

postgresql-9.5 数据库路径迁移

摘要: 原因: 因存放数据库的目录磁盘空间已满,故需要将数据库迁移到其他目录 步骤: 1 postgresql安装后,默认的数据库路径是/var/lib/pgsql/9.x/data 2 新建文件夹 新建路径作为新的数据库数据路径,例如:/home/data mkdir /home/data 授权(必须输入 阅读全文

posted @ 2019-08-23 13:38 Helianthus720 阅读(594) 评论(0) 推荐(0) 编辑

2019年8月19日

启动nginx 提示:nginx: [emerg] bind() to 0.0.0.0:8082 failed (13: Permission denied)

摘要: 原因: selinux 开启导致 输入:getenforce 命令可以查看当前是否开启selinux 输出 disabled 或 permissive 那就是关闭了输出 enforcing 则是开启了 selinux 解决: 1 临时关闭 setenforce 0 ##设置SELinux 成为per 阅读全文

posted @ 2019-08-19 10:48 Helianthus720 阅读(857) 评论(0) 推荐(0) 编辑

上一页 1 ··· 3 4 5 6 7 8 下一页

导航