Two SumGiven an array of integers, find two numbers such that they add up to a specific target number.The function twoSum should return indices of the...
分类:
其他好文 时间:
2014-12-28 11:38:19
阅读次数:
134
当Dialog有编辑框时如果选择会弹菜单窗口就不要用package com.android.autologin;import android.app.Activity;import android.app.AlertDialog;import android.content.DialogInterf...
分类:
其他好文 时间:
2014-12-28 10:21:00
阅读次数:
685
Description: Railway tickets were difficult to buy around the Lunar New Year in China, so we must get up early and join a long queue… The Lunar New .....
分类:
其他好文 时间:
2014-12-28 00:25:48
阅读次数:
147
Starting and running a business can provide a lot of satisfactions.I can be my own boss, keep schedule of my own, and answer to nobody but myself.If I...
分类:
其他好文 时间:
2014-12-27 21:39:15
阅读次数:
367
我从ABS切换到AppCompat与Material theme(仅适用于API21)
我的配置文件如下:
<application
android:theme="@style/AppStyle"
我的 activity:
public class AudioRec...
分类:
移动开发 时间:
2014-12-27 20:32:58
阅读次数:
173
#include
#include
#include
#include
#define LEFT 0x4b00
#define RIGHT 0x4d00
#define DOWN 0x5000
#define UP 0x4800
#define ESC 0x011b
#define N 100/*贪吃蛇的最大长度*/
int i,key;
int speed;/*游戏速...
分类:
其他好文 时间:
2014-12-27 17:37:10
阅读次数:
237
We want to count all the books in the library. You count up shelf #1, I count up shelf #2. That's map. The more people we get, the faster it goes.我们要数...
分类:
其他好文 时间:
2014-12-27 15:03:58
阅读次数:
106
Git使用方法-下载子模块本文地址:http://blog.csdn.net/caroline_wendy代码托管在Git上比较方便管理,如计步器;使用Git的代码,需要下载,可以手动的Clone代码,解压加载;创建文件夹,在文件夹内使用命令:下载项目:git clone git@git.chunyu.mobi:android/pedometer.git下载子模块:git submodule up...
分类:
系统相关 时间:
2014-12-27 08:57:19
阅读次数:
166
今天很是苦恼,明明设置了android:showAsAction="always",但是所有的items全部都显示在overflow中,然后在官网发现了答案。如果你为了兼容 Android 2.1 的版本使用了 Support 库,在android命名空间下showAsAction属性是不可用的。S...
分类:
其他好文 时间:
2014-12-27 00:16:49
阅读次数:
273
Given a linked list, determine if it has a cycle in it.
Follow up:
Can you solve it without using extra space?
题目的意思是判断链表中有没有环
思路:
定义两个指针,一个慢指针,一个快指针,慢指针一次走两步,快指针一次走一步,如果有环,那么慢、快指针一...
分类:
其他好文 时间:
2014-12-26 20:20:32
阅读次数:
191