2016年9月3日

再探VIM配置

摘要: 再探VIM配置 最初找到这个发行版 "spf13 vim" ,在ubuntu上用的还比较方便,有很多插件;最近在mac上用,总是不兼容vim,用brew安装了最新的vim,还是跟系统不兼容,总是有问题,于是就找到了下面第二个配置。 "vim-config" ,这哥们基于vundle配置了一些有用的插 阅读全文

posted @ 2016-09-03 00:13 xweel 阅读(228) 评论(0) 推荐(0) 编辑

2016年9月1日

counting elements--codility

摘要: "lesson 4: counting elements " "1. FrogRiverOne" "2. PermCheck" "3. MissingInteger" "4. MaxCounters" lesson 4: counting elements exercise Problem: You 阅读全文

posted @ 2016-09-01 23:46 xweel 阅读(534) 评论(0) 推荐(0) 编辑

Time complexity--codility

摘要: lesson 3: Time complexity exercise: Problem: You are given an integer n. Count the total of 1+2+...+n. 1. TapeEquilibrium [100%] Minimize the value |( 阅读全文

posted @ 2016-09-01 23:44 xweel 阅读(236) 评论(0) 推荐(0) 编辑

Arrays--codility

摘要: lesson 2: Arrays exercise: Problem: Given array A consisting of N integers, return the reversed array. 1. CyclicRotation [100%] Rotate an array to the 阅读全文

posted @ 2016-09-01 23:40 xweel 阅读(296) 评论(0) 推荐(0) 编辑

Iterations --codility

摘要: lesson 1:Iterations 1. BinaryGap [100%] Find longest sequence of zeros in binary representation of an integer. A binary gap within a positive integer 阅读全文

posted @ 2016-09-01 23:35 xweel 阅读(189) 评论(0) 推荐(0) 编辑

2016年8月31日

adobe reader DC 字体设置

摘要: adobe reader DC 字体设置 一直使用adobe reader阅读pdf文档,系统提醒我升级一个reader助手, 升级之后: 感觉字体颜色变浅,笔画也变细了,整体有些模糊不清。 google了一下,原来是设置的 "问题" 在菜单中依次可以找到如下的设置: edit preference 阅读全文

posted @ 2016-08-31 15:51 xweel 阅读(1128) 评论(0) 推荐(0) 编辑

2016年8月30日

按位操作

摘要: 按位操作 异或 异或自己 变成零 异或零,值不变 与 & 递归与自己的减一按位与,返回的是该数化为二进制数后,数字1的个数 int fun(int x){ int c = 0; while(x){ c++; x = x&(x 1); cout 阅读全文

posted @ 2016-08-30 18:54 xweel 阅读(132) 评论(0) 推荐(0) 编辑

Microsoft Visual Studio小技巧

摘要: main函数调试参数: Project -> Properties -> Configuration Properties -> Debugging 在Command Arguments里填上即可。 阅读全文

posted @ 2016-08-30 18:51 xweel 阅读(202) 评论(0) 推荐(0) 编辑

数据的对齐

摘要: 数据的对齐 cpu在读写内存的时候,如果所给的地址是机器字长的整数倍,则操作效率会比较高,这可以称之为地址的对齐。 在一般的32bits机器上,地址对齐的界线默认是4的整数倍。 struct my_struct{ char ch1; //1字节 char ch2; //1字节 int n; //4字 阅读全文

posted @ 2016-08-30 18:50 xweel 阅读(331) 评论(0) 推荐(0) 编辑

c/c++程序设计涉及的一些知识点

摘要: c/c++程序设计涉及的一些知识点 c中的printf函数 main(){ int b = 3; int arr[]= {6,7,8,9,10}; int ptr = arr; (ptr++) += 123; printf("%d,%d\n", ptr, (++ptr)); return 0; } 阅读全文

posted @ 2016-08-30 18:47 xweel 阅读(558) 评论(0) 推荐(0) 编辑

导航