自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

Happiness is more than pleasure without pain

你必须非常努力,才能看起来毫不费力

  • 博客(6)
  • 资源 (2)
  • 问答 (1)
  • 收藏
  • 关注

原创 Single Number II

Given an array of integers, every element appears three times except for one. Find that single one. Note: Your algorithm should have a linear runtime complexity. Could you implement it without usi

2015-03-27 19:18:51 432

原创 简单工厂和工厂方法

简单工厂:一个工厂类根据传入的参量决定创建出哪一种产品类的实例 直接一个工厂类,内部通过 swith(operator) {     case"+": oper=new AddOperation();//产生对象     ... 而工厂方法模式:定义一个用于创建对象的接口,让子类决定实例化哪一个类。工厂方法使一个类的实例化延迟到其子类。 定义一个接口 DAO Add类实现该接口:Ad

2015-03-27 16:28:23 298

原创 Implement strStr()

Implement strStr(). Returns the index of the first occurrence of needle in haystack, or -1 if needle is not part of haystack. Update (2014-11-02): The signature of the function had been updat

2015-03-27 13:50:05 369

原创 Linked List Cycle II

Given a linked list, return the node where the cycle begins. If there is no cycle, return null. Follow up: Can you solve it without using extra space? /**  * Definition for singly-linked l

2015-03-26 23:17:04 275

原创 Linked List Cycle

//快慢指针 public class Solution { public boolean hasCycle(ListNode head) { if(head==null)return false; ListNode slow=head; ListNode fast=head; do{ if(fast==null||fast.next==null)return false; f

2015-03-26 22:34:22 290

原创 剑指offer总结

1、实现Singleton模式 2、二维数组中的查找:每行从左到右递增,每列从上到下递增,输入一个数,判断数组中是否存在该数 1 2  8 9  2 4  9 12 4 7 10 13  6 8 11 15 如输入7: 小于第4列的9,则不可能在第4列;column-- 小于第3列的8,则不可能在第3列;column-- 大于第二列的2,则row++; 始终比较右上角的

2015-03-26 15:06:38 365

Android应用开发揭秘源码

全书的源码都有,很详细,用起来很方便,直接导入即可用

2014-05-02

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除