摘要: 1.首先gdb编译: gcc -g xxx.c -o xxx 2.然后 gdb xxx进入调试 break 行号 加入断点 (1)然后run就能够跑到下一个断点 (2)step(或s)单步跟踪 (3)print可(或p)以查看当前程序的执行数据 比方:print a 输出a变量的值 输出格式能够设置 阅读全文
posted @ 2017-04-19 20:56 cxchanpin 阅读(1825) 评论(0) 推荐(0)
摘要: 编写thrift文件是,须要知道thrift文件支持的数据类型有哪些。假设定义Service等。以下是官方文档的说明: # # Thrift Tutorial # Mark Slee (mcslee@facebook.com) # # This file aims to teach you how 阅读全文
posted @ 2017-04-19 19:48 cxchanpin 阅读(3402) 评论(0) 推荐(0)
摘要: struct 1、结构体和数组的差别:能够再结构体里声明数组。结构体变量能够相互赋值。而数组不行。 2、struct与class的差别:class的成员訪问权限默认是private,而struct成员的是public。 3、结构体的定义: (1)可递归。结构体内部能够使用指针指向自己。比如。链表。 阅读全文
posted @ 2017-04-19 19:14 cxchanpin 阅读(212) 评论(0) 推荐(0)
摘要: 报错提示: Fatal error: Function name must be a string in D:\wwwroot\zbphp.com\ThinkPHP\Library\Behavior\ReadHtmlCacheBehavior.class.php on line 87 代码例如以下: 阅读全文
posted @ 2017-04-19 19:13 cxchanpin 阅读(225) 评论(0) 推荐(0)
摘要: 自上周怒辞职以后,就開始苦逼的各种面试生涯,生活全然靠私活来接济,时有时没有,真难。还能快乐的玩耍吗。最多一天面试了5家,哎感觉都是不急招人,各种等待通知。好不easy等来一家。还克扣了薪资,从我要的12k到他们给8k,感觉累觉不爱。 面试都是基本过了二面的,大到腾讯,阿里。百度。网易,小到15人的 阅读全文
posted @ 2017-04-19 18:00 cxchanpin 阅读(122) 评论(0) 推荐(0)
摘要: freemarker基本数据类型 1、基本数据类型 (1)字符串 (2)数字 (3)布尔值 (4)日期 2、展示演示样例 <html> <head> <meta http-equiv="content-type" content="text/html; charset=UTF-8"> <title> 阅读全文
posted @ 2017-04-19 16:21 cxchanpin 阅读(393) 评论(0) 推荐(0)
摘要: (一) 那么当程序的控制流到达这个变量定义时。变承受构造成本;当变量离开作用域时。便承受析构成本。 string encryptPassword(const std::string& password) { using namespace std; string encrypted; if(pass 阅读全文
posted @ 2017-04-19 15:24 cxchanpin 阅读(193) 评论(0) 推荐(0)
摘要: 在Hive中,须要实现Hive中的函数无法实现的功能时,就能够用Streaming来实现。其原理能够理解成:用HQL语句之外的语言,如Python、Shell来实现这些功能,同一时候配合HQL语句,以实现特殊的功能。 比方,我有一张不同站点訪问的日志表,当中有两个列是url和ref。分别代表当前訪问 阅读全文
posted @ 2017-04-19 14:07 cxchanpin 阅读(1435) 评论(0) 推荐(0)
摘要: 希尔排序思想:使数组中随意间隔为h的元素都是有序的。希尔排序是插入排序的优化。先对数组局部进行排序,最后再使用插入排序将部分有序的数组排序。 代码例如以下: /** * * @author seabear * */ public class ShellSort { public static voi 阅读全文
posted @ 2017-04-19 13:02 cxchanpin 阅读(293) 评论(0) 推荐(0)
摘要: 在希望通过函数的參数返回Objective-C对象的时候。遇到了这个问题 错误代码例如以下: - (void)methodA:(NSString **)string<span style="white-space:pre"> </span>// 事实上。这里的參数实际类型是:(NSString * 阅读全文
posted @ 2017-04-19 13:01 cxchanpin 阅读(996) 评论(0) 推荐(0)