题目传送门 1 #include 2 #include 3 #define lson l, m, rt > 1;23 build (lson);24 build (rson);25 }26 27 int update(int p, int l, int r, int rt)28 ...
分类:
其他好文 时间:
2015-05-15 19:53:15
阅读次数:
118
最近,有于业务场景需要,得把服务器上的某些碍事的用户踢掉,呵呵,废话不说了,方法有两种
1.先用w(或者who)查看有谁登陆在服务器上:
2.下面,我们需要把从192.168.56.2机器上登陆的caesar用户踢掉
(1).通过pkill -kill -t pts/6踢掉
(2).先通过ps -ef | grep pts/6命令查找对应的进程号
然后在把进程42...
分类:
系统相关 时间:
2015-05-15 15:38:05
阅读次数:
152
1639 - CandyTime limit: 3.000 seconds1639 CandyLazyChild is a lazy child who likes candy very much. Despite being very young, he has two large candy b...
分类:
其他好文 时间:
2015-05-14 23:27:49
阅读次数:
215
题目链接:http://poj.org/problem?id=2886题意:N个人坐成一个圈,每个人都有个值A代表这他左边或右边的第A个人出圈,刚开始第k个人出圈。第i个人出圈得到价值为i的因子数的个数。求出圈价值最大的那个人。思路:因为数据N为500000,所以需要利用线段树。不需要考虑N个人坐成一圈,认为N个人排成一个队列。每次更新当前队列中第k个人出圈,得到出圈人的下标。代码如下:#inclu...
分类:
其他好文 时间:
2015-05-14 14:15:44
阅读次数:
94
用户及用户组管理命令汇总命令总结:useradd,usermod,userdel,passwdgroupadd,groupdel,groupmod,gpasswd,newgrpchage,chsh,chfn,who,id,fingersu,w============================================================================================================文件总结:/..
分类:
其他好文 时间:
2015-05-14 06:22:29
阅读次数:
199
QuestionThere was a murder in the home of a married couple, their son and daughter. One of these 4 people murdered one of the others.One of the member...
分类:
其他好文 时间:
2015-05-13 16:32:12
阅读次数:
113
1 /* 2 * (C) Copyright 2003 3 * Wolfgang Denk, DENX Software Engineering, wd@denx.de. 4 * 5 * See file CREDITS for list of people who contri...
分类:
其他好文 时间:
2015-05-13 12:03:24
阅读次数:
215
在Linux中who系列命令存在who/whoami/whoami。首先我以普通用户guixian001登陆系统。然后执行命令分别执行命令whoami/whoami/who。截图如下:然后我们使用su命令切换到root用户再执行以上三个命令。看出区别了吗?使用whoami命令显示的是当前“操作用户”的用户名。而whoami显..
分类:
系统相关 时间:
2015-05-12 11:42:03
阅读次数:
123
题目如下:
At the beginning of every day, the first person who signs in the computer room will unlock the door, and the last one who signs out will lock the door. Given the records of signing in's and...
分类:
其他好文 时间:
2015-05-11 22:08:58
阅读次数:
138
1、who:判断谁在系统上,查看用户自己的信息用 who i am。2、ps aux:列出当前在机器上运行的所有进程的详细列表。3、ls:列出当前目录的内容。4、cat:查看文件内容。5、which +命令:查看所使用的命令所在的文件,如 which ps。6、reset:将终端恢复到正常状态。7、...
分类:
系统相关 时间:
2015-05-11 19:56:21
阅读次数:
159