引号的特殊效果就是,
保护字符串中特殊字符不被shell或者shell脚本重新解释或扩展(这里所说的”特殊”指的是一些字符在shell中具有特殊意义, 例如*)ls –l
[vV]"*ls –l ‘[vV]*’我们使用引号来引用一个字符串, 目的是保护它的字面含义.特定的工具或程序可以重新解释在引号...
分类:
其他好文 时间:
2014-05-12 16:20:58
阅读次数:
235
需求是我们需要对服务器上的流量进行监控,网络上有个流传的check_traffic.sh,它需要被监控机开启snmp。但是感觉都使用上了nagios还要开snmp。。。有点斧子剪刀一起用的感觉,所以就动手写了个监控流量的shell:#!/bin/shusage()
{ echo "Usage: $0...
分类:
移动开发 时间:
2014-05-06 08:46:56
阅读次数:
361
Say you have an array for which theithelement
is the price of a given stock on dayi.Design an algorithm to find the maximum
profit. You may complete a...
分类:
其他好文 时间:
2014-05-06 00:51:29
阅读次数:
353
epoll函数#include int epoll_create(int size)int
epoll_ctl(int epfd, int op, int fd, struct epoll_event *event)int epoll_wait(int
epfd,struct epoll_event...
分类:
其他好文 时间:
2014-05-06 00:21:30
阅读次数:
519
Problem
Link:http://oj.leetcode.com/problems/longest-consecutive-sequence/This problem
is a classical problem where we can reduce the running time by ...
分类:
其他好文 时间:
2014-05-05 22:55:22
阅读次数:
552
Link:http://oj.leetcode.com/problems/reverse-nodes-in-k-group/Given a linked
list, reverse the nodes of a linked listkat a time and return its modifie...
分类:
其他好文 时间:
2014-05-05 22:46:42
阅读次数:
456
拼图Time Limit:1000MSMemory
Limit:65535KBSubmissions:117Accepted:69Description给你1x2、2x1和2x2,3种矩形若干,请你计算出把它们放入2xn的矩形中,一共有多少方法?Input输入有多组测试数据没行输入一个整数n
, 3...
分类:
其他好文 时间:
2014-05-05 22:35:15
阅读次数:
435
挑战题之排列生成Time Limit:2000MSMemory
Limit:65535KBSubmissions:435Accepted:170Description一自然数N,设N为3,则关于N的字典序排列为123,132,213,231,312,321。对于一个自然数N(1#include
us...
分类:
其他好文 时间:
2014-05-05 22:25:33
阅读次数:
294
Excuses, Excuses!
Time Limit: 1000MS
Memory Limit: 10000K
Total Submissions: 3615
Accepted: 1254
Description
Judge Ito is having a problem with people subpoenaed fo...
分类:
其他好文 时间:
2014-05-03 17:10:03
阅读次数:
278
A + B
Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)
Total Submission(s): 11543 Accepted Submission(s): 6699
Problem Description
读入两个小于100的正整数A和B,计...
分类:
其他好文 时间:
2014-05-03 16:00:57
阅读次数:
270