题目:查找元素target插入一个数组中的位置。代码:public int
searchInsert(int[] A, int target) { int len = A.length; int i; for(i = 0 ; i
< len ; i++){ ...
分类:
其他好文 时间:
2014-05-18 20:28:13
阅读次数:
299
#include #include int main(/*int argc, char const
*argv[]*/){ void * target; time_t now = time(NULL); if(now & 1) target =
&&odd; else target = &&e...
分类:
其他好文 时间:
2014-05-18 20:27:53
阅读次数:
306
asdasdasdasdaasdasdasdasda
分类:
Web程序 时间:
2014-05-18 20:27:17
阅读次数:
280
今天制作了一个响应式导航条,能够自动随着不同的屏幕分辨率或浏览器窗口大小的不同而改变导航条的样式,这里主要用到的就是CSS3的Media
Query。具体可以查看浅谈响应式布局这篇文章,这里就不花费大量的篇幅介绍了,主要看一下这个导航条该怎么做。另外需要提到的是,ie6-ie8是不支持CSS3的Me...
分类:
Web程序 时间:
2014-05-18 19:33:42
阅读次数:
403
使用了几种办法
1:使用Qt下面的QListview来实现QQ类似效果,差强人意
2:使用QWebview加载html css样式来完成,发现效果不错,但是毕竟webview占用巨大的内存
3:使用QTextBrower加载css,但是好像只支持css2.1版本,css3完全不支持,这样的话,花哨的样式应该是无法实现...
分类:
其他好文 时间:
2014-05-18 15:02:04
阅读次数:
500
4Sum
Given an array S of n integers, are there elements a, b, c, and d in S such that a + b + c + d = target? Find all unique quadruplets in the array which gives the sum of target....
分类:
其他好文 时间:
2014-05-18 13:49:09
阅读次数:
306
题目:给一个数组和给定的目标值,要求在数组里找出三个元素,这三个元素的和最接近目标值,当然等于是最好的。
用3sum的方法,把判定条件作些修改。
int twoSum(vector &num, int start, int target)
{
if(num.size() = num.size())
return -target;
int head = start;
int t...
分类:
其他好文 时间:
2014-05-18 10:49:12
阅读次数:
217
分享2014-4-1
HTML5上课笔记
2、CSS3属性(内核前缀)
Mozilla 内核 css前缀-moz;
WebKit 内核 css前缀-webkit ;(谷歌已换用blink内核)
Opera 内核 css前缀 -o ; (欧朋已换用blink内核)
Trident 内核 css前缀 -ms ;
...
分类:
Web程序 时间:
2014-05-18 10:37:02
阅读次数:
592
3SumClosest
Given an array S of n integers, find three integers in S such that the sum is closest to a given number, target. Return the sum of the three integers. You may assume that each input would have exactly one solution....
分类:
其他好文 时间:
2014-05-18 05:57:48
阅读次数:
244
CSS的font-family属性使网页可以使用客户电脑里的字体,从而得到多姿多彩的WEB页面,但当客户端没有你想要使用的字体时怎么办呢?我们总不能让每个访问者都去安装一个字体吧?事实上,这是可以的!不过不是访客主动下载的,而是网站开发者帮访客下载安装的,具体怎么实现的,我们还要从字体文件的格式说起...
分类:
Web程序 时间:
2014-05-17 20:14:45
阅读次数:
351