上一页 1 ··· 10 11 12 13 14 15 16 17 18 ··· 51 下一页
摘要: pgrep 运行的程序 [root@c1 ~]# pgrep matmul 2634730 阅读全文
posted @ 2022-06-28 15:17 我在路上回头看 阅读(21) 评论(0) 推荐(0) 编辑
摘要: from collections import MutableMapping class SortedDict(MutableMapping): def __init__(self): self.data = {} def __getitem__(self, key): return self.da 阅读全文
posted @ 2022-06-25 09:35 我在路上回头看 阅读(38) 评论(0) 推荐(0) 编辑
摘要: def populate_ranks(votes, ranks): names = list(votes.keys()) names.sort(key=votes.get, reverse=True) for i, name in enumerate(names, 1): ranks[name] = 阅读全文
posted @ 2022-06-25 09:23 我在路上回头看 阅读(26) 评论(0) 推荐(0) 编辑
摘要: http://t.zoukankan.com/carriezhangyan-p-9359708.html https://blog.csdn.net/weixin_28917223/article/details/113006958 http://nginx.org/en/docs/http/ngx 阅读全文
posted @ 2022-06-08 16:47 我在路上回头看 阅读(79) 评论(0) 推荐(0) 编辑
摘要: $args #请求中的参数值 $query_string #同 $args $arg_NAME #GET请求中NAME的值 $is_args #如果请求中有参数,值为"?",否则为空字符串 $uri #请求中的当前URI(不带请求参数,参数位于$args),可以不同于浏览器传递的$request_u 阅读全文
posted @ 2022-06-08 15:09 我在路上回头看 阅读(881) 评论(0) 推荐(1) 编辑
摘要: from os import path print(path.relpath("/home/hpcadmin/lw/demo.py", start="/home/hpcadmin/lw")) # start可以指定路径 print(path.basename("/home/hpcadmin/lw/d 阅读全文
posted @ 2022-06-08 11:11 我在路上回头看 阅读(108) 评论(0) 推荐(0) 编辑
摘要: centos7 # 先配阿里源 mv /etc/yum.repos.d/CentOS-Base.repo /etc/yum.repos.d/CentOS-Base.repo.backup curl -o /etc/yum.repos.d/CentOS-Base.repo https://mirror 阅读全文
posted @ 2022-05-27 18:50 我在路上回头看 阅读(154) 评论(0) 推荐(0) 编辑
摘要: 概述 go语言中的MPG线程模型对两级线程模型进行了一定程度的改进,使它能够更加灵活的进行线程之间的调度。 它由3个主要模块构成,如下图: MPG的3个主要模块以及功能,我们通过下表所示。 | 模块 | 功能说明 | | | | | Machine | 一个Machine对应一个内核线程,相当于内核 阅读全文
posted @ 2022-05-20 10:49 我在路上回头看 阅读(198) 评论(0) 推荐(0) 编辑
摘要: >>> docker network create -d bridge bridge-net # 创建一个名为bridge-net的网络 # 测试,启动两个容器,并且接入到bridge-net网络中 >>> docker run -it --name alpine1 --network bridge 阅读全文
posted @ 2022-05-18 12:10 我在路上回头看 阅读(180) 评论(0) 推荐(0) 编辑
摘要: 问题 我们想在某个集合中找出最大或最小的N个元素 解决方案 heapq模块中有两个函数nlargest()和nsmallest() import heapq nums = [1,8,2,23,7,-4,18,23,42,37,2] print(heapq.nlargest(3,nums)) # [4 阅读全文
posted @ 2022-05-16 18:21 我在路上回头看 阅读(181) 评论(0) 推荐(0) 编辑
上一页 1 ··· 10 11 12 13 14 15 16 17 18 ··· 51 下一页