自定义博客皮肤VIP专享

*博客头图:

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

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

博客底图:

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

栏目图:

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

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+

dh_chen

从小立志做名低俗的诗人~_~ ——享受技术学习带来的喜悦

  • 博客(21)
  • 收藏
  • 关注

原创 leetcode 101. Symmetric Tree

题目描述:Given a binary tree, check whether it is a mirror of itself (ie, symmetric around its center).For example, this binary tree [1,2,2,3,4,4,3] is symmetric: 1 / \ 2 2 / \ / \

2016-06-19 23:53:26 342

原创 leetcode 27. Remove Element

题目描述:Given an array and a value, remove all instances of that value in place and return the new length.Do not allocate extra space for another array, you must do this in place with constant

2016-06-19 18:32:35 352

原创 leetcode 198. House Robber

题目描述:You are a professional robber planning to rob houses along a street. Each house has a certain amount of money stashed, the only constraint stopping you from robbing each of them is that adj

2016-06-19 17:31:36 316

原创 leetcode 142. Linked List Cycle II

题目描述:Given a linked list, return the node where the cycle begins. If there is no cycle, return null.Note: Do not modify the linked list.Follow up:Can you solve it without using extra s

2016-06-19 11:23:00 358

原创 leetcode 141. Linked List Cycle

题目描述:Given a linked list, determine if it has a cycle in it.Follow up:Can you solve it without using extra space?解题思路:这道题比较简单,用两个指针就可以了。/** * Definition for singly-linked list. * s

2016-06-19 10:15:29 328

原创 hiho #1033 : 交错和

题目描述:时间限制:10000ms单点时限:1000ms内存限制:256MB描述给定一个数 x,设它十进制展从高位到低位上的数位依次是 a0, a1, ..., an - 1,定义交错和函数:f(x) = a0 - a1 + a2 - ... + ( - 1)n - 1an - 1例如:f(3214567) = 3 - 2 + 1

2016-06-18 18:13:44 1253

原创 hdu HDU 3555 Bomb

题目描述:题目链接Time Limit: 2000/1000 MS (Java/Others)    Memory Limit: 131072/65536 K (Java/Others)Total Submission(s): 13265    Accepted Submission(s): 4765Problem DescriptionThe counter-

2016-06-14 22:01:02 476

原创 MySQL多列索引

多列索引(Multiple-Column Indexes)也称为复合索引(composite index),也即同时对多个列建立索引。那么问题来了,建立多列索引后,例如建立索引(a, b, c),那么单独对a或者b或者c进行查询,会走索引这条路线吗?答案是:根据最左前缀原则,也就是对a或者(a,b)或者(a, b, c)查询会用到索引,但以b或者c来查询而不加上a则不会走索引,

2016-06-13 17:16:14 1641

原创 51nod 1001 数组中和等于K的数对

题目描述:基准时间限制:1 秒 空间限制:131072 KB 分值: 5 难度:1级算法题给出一个整数K和一个无序数组A,A的元素为N个互不相同的整数,找出数组A中所有和等于K的数对。例如K = 8,数组A:{-1,6,5,3,4,2,9,0,8},所有和等于8的数对包括(-1,9),(0,8),(2,6),(3,5)。I

2016-06-11 21:41:05 898

原创 Code jam Problem A. Minimum Scalar Product

题目描述:ProblemYou are given two vectors v1=(x1,x2,...,xn) and v2=(y1,y2,...,yn). The scalar product of these vectors is a single number, calculated as x1y1+x2y2+...+xnyn.Suppose you are allowe

2016-06-11 18:15:56 705

原创 51nod 1459 迷宫游戏

题目描述:基准时间限制:1 秒 空间限制:131072 KB 分值: 0 难度:基础题 收藏 关注你来到一个迷宫前。该迷宫由若干个房间组成,每个房间都有一个得分,第一次进入这个房间,你就可以得到这个分数。还有若干双向道路连结这些房间,你沿着这些道路从一个房间走到另外一个房间需要一些时间。游戏规定了你的起点和终点房间,你首要目标

2016-06-11 11:06:34 736

原创 51nod 1770 数数字

51nod 1770 数数字

2016-06-09 19:12:57 478

原创 sicily 1156. Binary tree

sicily 1156. Binary tree

2016-06-09 00:00:23 749

原创 leetcode 83. Remove Duplicates from Sorted List

leetcode 83. Remove Duplicates from Sorted List

2016-06-08 22:23:20 295

原创 jdk之Interger.toString(int i, int radix)

jdk之Interger.toString(int i, int radix)

2016-06-07 00:50:29 3160 1

原创 leetcode 326. Power of Three

leetcode 326. Power of Three

2016-06-07 00:40:53 359

原创 leetcode 191. Number of 1 Bits

leetcode 191. Number of 1 Bits

2016-06-06 21:54:20 333

原创 leetcode 242. Valid Anagram

leetcode 242. Valid Anagram

2016-06-03 00:46:03 352

原创 Sicily 1334 数列

Sicily 1334数列

2016-06-03 00:23:49 493

原创 leetcode 322. Coin Change

leetcode Coin Change

2016-06-02 01:03:32 451

原创 java synchronized关键字

synchronized小结

2016-06-01 21:21:14 469

空空如也

空空如也

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

TA关注的人

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