题目:Given an input string, reverse the string word by word.For example,Given s = "the sky is blue",return "blue is sky the".要求:1)首尾有空格的时候,反转后的string要将空...
分类:
其他好文 时间:
2014-07-16 19:29:54
阅读次数:
234
描述: Given two integersnandk, return all possible combinations ofknumbers out of 1 ...n.For example,Ifn= 4 andk= 2, a solution is:[ [2,4], [3,4], [2...
分类:
其他好文 时间:
2014-07-16 19:29:31
阅读次数:
166
在Qt5之前,串口通信基本依赖于第三方库,下面是我曾接触过的串口通信类库。 串口通信类库通信过程基本是一下步骤,即:打开串口 > 配置串口参数 > 收发数据。注意,串口参数(波特率、数据位、停止位、奇偶校验、流控等)必须在串口打开之后进行配置才有效。在使用串口接收数据时,会出现数据接收不完整的情况,...
分类:
其他好文 时间:
2014-07-15 23:32:19
阅读次数:
443
题目Given a binary tree containing digits from0-9only, each root-to-leaf path could represent a number.An example is the root-to-leaf path1->2->3which r...
分类:
其他好文 时间:
2014-07-15 23:21:33
阅读次数:
218
记录在项目中碰到的形形色色、杂杂碎碎的问题(持续更新至项目结束)qrc文件配置 Qt中有一个管理资源的文件,后缀名为qrc,本质是简单的XML文件格式。 项目开始时的内容为:1 2 3 4 5 例如在项目中要用到一个png图片来做图标 则可以写成(Resources文件夹与...
分类:
其他好文 时间:
2014-07-15 09:11:23
阅读次数:
268
HHyper Prefix SetsPrefix goodness of a set string is length of longest common prefix*number of strings in the set. For example the prefix goodness of ...
分类:
其他好文 时间:
2014-07-15 08:51:08
阅读次数:
261
编译环境Ubuntu 12.04 (32或者64位)安装Gitsudo apt-get install git安装编译工具sudo apt-get install build-essential安装cmakesudo apt-get install cmake安装qt4sudo apt-get in...
分类:
其他好文 时间:
2014-07-13 19:17:16
阅读次数:
276
Python provides methods that operate on lists. For example, append adds a new element to the end of a list, extend takes a list as an argument and app...
分类:
其他好文 时间:
2014-07-13 19:16:32
阅读次数:
236
Android仿IOS回弹效果 ScrollView回弹 总结
应项目中的需求 需要仿IOS 下拉回弹的效果 , 我在网上搜了很多 大多数都是拿scrollview 改吧改吧
试了一些 发现总有点小问题
下面的代码是我对大家发布的做了点小修改 觉得没太大问题
package com.example.myscrollview;
import android.content...
分类:
移动开发 时间:
2014-07-13 18:49:40
阅读次数:
252
Given a binary tree, return the preorder traversal of its nodes' values.
For example:
Given binary tree {1,#,2,3},
1
2
/
3
return [1,2,3].
/**
* Definition for bi...
分类:
其他好文 时间:
2014-07-13 18:46:25
阅读次数:
249