10 2019 档案
摘要:a=[1,2,3,4,5,6,7,8] b=[i**2 for i in a if i >= 5] print b
阅读全文
摘要:# requirepass foobaredrequirepass 123 指定密码123 https://www.cnblogs.com/x-ll123/p/9717351.html
阅读全文
摘要:find . -type f -size +800M du -h --max-depth=1 |grep 'G' |sort 哪个文件夹占用高
阅读全文
摘要:from redis import ConnectionPool, Redis pool = ConnectionPool(host='localhost',password='aaa123', port=6379, db=0, decode_responses=True) rdb = Redis(
阅读全文
摘要:d = 7 sw={ 0:'sun', 1:'tue', 2:'wed' } name =sw.get(d,'unkown') print(name) def get_sum(): return 'sum' def get_mon(): return 'mon' def get_default(): return 'default' sw={ 0:get_sum, 1:get_mon, } d =
阅读全文
摘要:import time def decorator(func): def wrapper(): print time.time() func() return wrapper def f1(): print('xxxxxx') f= decorator(f1) f() import time def decorat...
阅读全文
摘要:from functools import reduce list_x = ['1','2','3','4','5'] r= reduce(lambda x,y:x+y,list_x,'aaa') print r --aaa12345
阅读全文
摘要:https://blog.csdn.net/weixin_42434700/article/details/143362373 从这里找下载包 https://unofficial-builds.nodejs.org/download/release/ 解压后直接 加环境变量 vim /etc/pr
阅读全文
摘要:1, 安装 2. 修改 配置 文件 ,后台 启动 vim /etc/redis.conf 找到 daemonize 属性 将no改为yes 3.启动 redis-server /etc/redis.conf & 解决Redis错误MISCONF Redis is configured to save
阅读全文
摘要:把 all_urls 这个list 的每一个 值 ,进行前面的表达式判断 list_x = [1,0,1,0,0,1] r = filter(lambda x: True if x==1 else False,list_x ) print(list(r))
阅读全文
摘要:前言, 使用 国内 代理 源 安装 1.安装 2.查看 有哪些 环境 3.设置 虚拟环境 位置 4.创建 虚拟 环境 5 .跳出 进入 包安装 失败 到 这个 网站 找 6.指定 python 版本 安装 路径 空格 环境名字 linux 里 安装 1 下面是不方便的版本 1.安装 2.新建环境 会
阅读全文
摘要:SELECT count(DISTINCT SCAC) FROM biao WHERE BASE_CODE = 'cnsha'
阅读全文
摘要:<!DOCTYPE HTML> <html> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"> <title>无标题文档</title> <style> ul { padding:0; margin:0; } li { list-style:none; } body { background:#33
阅读全文