题目:
Given a linked list, reverse the nodes of a linked list k at a time and return its modified list.
If the number of nodes is not a multiple of k then left-out nodes in the end should remain...
分类:
其他好文 时间:
2015-05-06 18:03:38
阅读次数:
132
#include
#include
//#include
int main()
{
std::vector ivec(10, 0);
int num;
for(std::vector::iterator iter=ivec.begin(); iter!=ivec.end();
++iter)
{
std::cin >> num...
分类:
编程语言 时间:
2015-05-06 18:03:35
阅读次数:
146
pig是处理流 的工具,所以数据集是流对象,处理步骤也是一样的。
Pig中存在按条件处理流对象的方式有
1)filter
X= FILTER A BY (f1 == 8);
2)CASE WHEN THEN ELSE END
CASE expression [ WHEN value THEN value ]+ [ELSE value ]? END
3)B...
分类:
其他好文 时间:
2015-05-06 17:58:04
阅读次数:
99
1、改变高度
自定义UINavigationBar的新类别:
[cpp] view
plaincopy
//UINavigationBar+BackgoundImage.h
#import
@interface UINavigationBar (BackgoundImage)
@end
在新...
分类:
移动开发 时间:
2015-05-06 17:46:32
阅读次数:
243
@interface PTABabyEditBaseVC ()@property (nonatomic) UIImagePickerController *imagePickerController;@end@implementation PTABabyEditBaseVC- (void)viewD...
分类:
其他好文 时间:
2015-05-06 16:53:39
阅读次数:
97
1.单链表代码:包含了尾插法,插入,删除操作。
有头结点的单链表也是为了在第一个位置插入和删除时候容易,不需要另外讨论
#include
#include
typedef struct Linklist
{
int key;
Linklist *next;
}Linklist;
Linklist* create_end()
{
Linklist *head=(Link...
分类:
编程语言 时间:
2015-05-06 15:05:03
阅读次数:
322
Ruby入门笔记一切皆为对象“Hello”.length方法定义:def开头 end结尾命名一般采用下划线分隔单词字符串中可以嵌入表达式返回值:a)return+返回值 b) 函数最后一行代码的值为返回值(太神奇了)类定义:class 开头 end结尾Initialize是构造方法@开头的变量是实例...
分类:
其他好文 时间:
2015-05-06 14:43:28
阅读次数:
203
##System Call## 先测试系统调用new/delete的用时。 ``` #include #include using namespace std; timespec diff(timespec start, timespec end) { timespec temp; if((end.tv_nsec-start.tv_nsec)<0) { temp.tv_...
分类:
其他好文 时间:
2015-05-06 13:30:38
阅读次数:
111
场景:在一个panel里面有非常多的自定义绘制的控件,在拖拉滚动条的时候,控件的画面上有残影不知道大家遇到过这种情况没,一直做web的winform经验太少,有更好的解决办法请贡献首先放出我的解决思路:需要再滚动停止的时候重绘一下控件,panel的所有事件都加了一个打印输出,发现,滚动条在滚动的时候...
VIM 技巧
match & replace match the whole word(eg: match printf but not snprintf/fprintf)You can use \ to match the end:
%s/\/PRINTF/gc
match the current...
分类:
其他好文 时间:
2015-05-06 12:44:36
阅读次数:
139