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

2013年10月12日

Linux shell编程

摘要: 1、按行读取文件内容: 方法1):while read linedo echo $linedone testfileThese sentences will be printed in testfile.`date +%Y%m%d`END_TEXT 3)here文档与shell函数:... 阅读全文

posted @ 2013-10-12 11:03 han'er 阅读(320) 评论(0) 推荐(0)

2013年10月11日

文本处理工具awk+sed+grep

摘要: 1、awk:pattern scanning and processing language 1)基本格式:awk 'pattern1{action1} pattern2{action2}...' filename,满足patternk则相应地执行actionk。其中,两种特殊的pattern... 阅读全文

posted @ 2013-10-11 20:04 han'er 阅读(466) 评论(0) 推荐(0)

2013年10月10日

C++ string

摘要: 1、写时复制(COW)。例子: 2、find系列的成员函数(可参照源码,如/usr/include/c++/4.1.2/bits/basic_string.tcc)。 首先需要了解,该系列的函数都返回string::size_type(无符号)类型。特殊值string::npos是size_type 阅读全文

posted @ 2013-10-10 15:49 han'er 阅读(474) 评论(0) 推荐(0)

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

导航