上一页 1 2 3 4 5 6 7 ··· 37 下一页

2015年5月6日

Bash新技能

摘要: 1. 输出数组全部元素1 echo ${array_name[@]}2. 输出数组长度1 echo ${#array_name[@]} #获得数组长度2 3 echo ${#string_name} #获得字符串长度3. 数组切片1 echo ${array_name[@]:2:3} #取下标从2开... 阅读全文

posted @ 2015-05-06 16:53 Stomach_ache 阅读(124) 评论(0) 推荐(0) 编辑

2015年5月5日

C++和G++手工开栈的=_=

摘要: 微软的编译器(C++)#pragma comment(linker, "/STACK:102400000,102400000") G++ int size = 256 << 20; // 256MB char *p = (char*)malloc(size) + size; __... 阅读全文

posted @ 2015-05-05 23:11 Stomach_ache 阅读(838) 评论(0) 推荐(0) 编辑

2015年4月17日

linux 编译C语言代码后产生OBJ文件的方法

摘要: 如果你不指定编译成什么文件,gcc默认一步到位,直接生成可执行文件你可以试试以下几个参数-c 只激活预处理,编译,和汇编,也就是他只把程序做成obj文件 例子用法: gcc -c hello.c 他将生成.o的obj文件-S 只激活预处理和编译,就是指把文件编译成为汇编代码。 例子用法 ... 阅读全文

posted @ 2015-04-17 20:54 Stomach_ache 阅读(3003) 评论(0) 推荐(0) 编辑

2015年4月14日

Touching segments(数据结构)

摘要: 题目链接Problem StatementYour Maths professor is a very nice guy, but he sometimes comes up with not so funny tasks. Today is one such day. The professor ... 阅读全文

posted @ 2015-04-14 20:25 Stomach_ache 阅读(311) 评论(0) 推荐(0) 编辑

Joining Byte Blocks(哈希+带花树)

摘要: 题目链接Problem StatementAs you are probably aware, the Internet protocols specify a canonical byte order convention for data transmitted over the network... 阅读全文

posted @ 2015-04-14 20:23 Stomach_ache 阅读(199) 评论(0) 推荐(0) 编辑

hihocoder 1084 (哈希)

摘要: 题目链接时间限制:4000ms单点时限:4000ms内存限制:256MB描述你知道KMP吗?它是用于判断一个字符串是否是另一个字符串的子串的算法。今天我们想去扩展它。在信息理论中,在两个相同长度的字符串之间的海明码距离是:两个字符串相同位置对应的字符不同的位置数目。换种说法,它表示将一个字符串转化为... 阅读全文

posted @ 2015-04-14 20:19 Stomach_ache 阅读(344) 评论(0) 推荐(0) 编辑

hihocoder 1036 (Trie图)

摘要: 题目链接AC代码: 1 #include 2 #include 3 #include 4 #include 5 #include 6 #include 7 #include 8 #include 9 #include 10 #include 11 #include 12 using... 阅读全文

posted @ 2015-04-14 20:13 Stomach_ache 阅读(141) 评论(0) 推荐(0) 编辑

2015年4月13日

POSIX基本正则表达式和扩展正则表达式的比较

摘要: 转自:http://book.51cto.com/art/201303/385961.htm在读者正觉得正则表达式已经复杂得不能再复杂时,又会发现POSIX规范将正则表达式的实现方法分为了两种:基本正则表达式(BRE)和扩展正则表 达式(ERE)。到目前为止,我们所讨论的正则表达式的所有特性,都得到... 阅读全文

posted @ 2015-04-13 14:34 Stomach_ache 阅读(241) 评论(0) 推荐(0) 编辑

2015年4月4日

让pandoc输出pdf时支持中文

摘要: 主机环境为:Ubuntu 12.04 LTS。对于RH系列,yum安装包的名称可能会有不同,不过yum联想能力比较强,应该不是问题。安装pandoc,安装tex-livesudo apt-get install pandoc texlive安装中文字体可以用“fc-list"命令查看已安装字体。使用... 阅读全文

posted @ 2015-04-04 11:10 Stomach_ache 阅读(723) 评论(0) 推荐(0) 编辑

2015年4月2日

Git - fatal error : Agent admitted failure to sign using the key

摘要: 提交时出现如下问题:1 git push -u origin master2 3 Agent admitted failure to sign using the key.4 Permission denied (publickey).5 fatal: The remote end hung up ... 阅读全文

posted @ 2015-04-02 17:35 Stomach_ache 阅读(172) 评论(0) 推荐(0) 编辑

上一页 1 2 3 4 5 6 7 ··· 37 下一页

导航