自定义博客皮肤VIP专享

*博客头图:

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

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

博客底图:

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

栏目图:

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

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(19)
  • 资源 (1)
  • 收藏
  • 关注

原创 Surrounded Regions-leetcode

题目:Given a 2D board containing 'X' and 'O', capture all regions surrounded by 'X'.A region is captured by flipping all 'O's into 'X's in that surrounded region.For example,X X X

2014-05-28 09:51:46 607

原创 leetcode题目:Sum Root to Leaf Numbers和Longest Consecutive Sequence

题目一:Given a binary tree containing digits from 0-9 only, each root-to-leaf path could represent a number.An example is the root-to-leaf path 1->2->3 which represents the number 123.Fin

2014-05-23 15:19:35 799

原创 leetcode题目:Palindrome Partitioning 和Palindrome Partitioning II

题目一:Given a string s, partition s such that every substring of the partition is a palindrome.Return all possible palindrome partitioning of s.For example, given s = "aab",Return [

2014-05-13 16:57:28 674

原创 leetcode题目:Clone Graph

题目:Clone an undirected graph. Each node in the graph contains a label and a list of its neighbors.OJ's undirected graph serialization:Nodes are labeled uniquely.We use # as a separat

2014-05-09 15:19:08 718

原创 leetcode题目:Candy

题目:There are N children standing in a line. Each child is assigned a rating value.You are giving candies to these children subjected to the following requirements:Each child must have at

2014-05-07 15:17:56 469

原创 leetcode题目:Single Number和Single Number II

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

2014-05-07 15:11:25 395

原创 leetcode题目:Copy List with Random Pointer

题目:A linked list is given such that each node contains an additional random pointer which could point to any node in the list or null.Return a deep copy of the list.思路:主要是深层复制的问题:本题比较简

2014-05-06 16:04:32 598

原创 leetcode题目:Word Break和Word Break II

题目一:Given a string s and a dictionary of words dict, determine if s can be segmented into a space-separated sequence of one or more dictionary words.For example, givens = "leetcode",dict

2014-05-06 15:59:22 1023

原创 leetcode题目:Linked List Cycle和Linked List Cycle II

题目一:Given a linked list, determine if it has a cycle in it.Follow up:Can you solve it without using extra space?题目二:Given a linked list, return the node where the cycle begins. If

2014-05-05 14:34:51 427

原创 leetcode题目:Reorder List

题目:Given a singly linked list L: L0→L1→…→Ln-1→Ln,reorder it to: L0→Ln→L1→Ln-1→L2→Ln-2→…You must do this in-place without altering the nodes' values.For example,Given {1,2,3,4}, reord

2014-05-05 10:41:22 441

原创 leetcode题目:Binary Tree Preorder Traversal

题目:Given a binary tree, return the preorder traversal of its nodes' values.For example:Given binary tree {1,#,2,3}, 1 \ 2 / 3return [1,2,3].Note: Recursi

2014-05-04 18:38:30 374

原创 leetcode题目:Binary Tree Postorder Traversal

题目:Given a binary tree, return the postorder traversal of its nodes' values.For example:Given binary tree {1,#,2,3}, 1 \ 2 / 3return [3,2,1].Note: Recurs

2014-05-04 17:10:33 360

原创 leetcode题目:LRU Cache

题目:Design and implement a data structure for Least Recently Used (LRU) cache. It should support the following operations: get and set.get(key) - Get the value (will always be positive) of th

2014-05-04 14:27:30 510

原创 leetcode题目解答---Insertion Sort List

题目如下:Sort a linked list using insertion sort.使用插入排序法排列一个链表。

2014-04-24 19:37:10 461

原创 leetcode题目解答---- SortList

题目:Sort a linked list in O(n log n) time using constant space complexity.这题还是比较纠结的,因为对于时间he

2014-04-24 17:33:51 561

原创 leetcode题目解答--Max Points on a Line

题目见下:Given n points on a 2D plane, find the maximum number of points that lie on the same straight line.解析思路:1)

2014-04-23 15:40:47 502

原创 leetcode题目--Evaluate Reverse Polish Notation 答案

题目见下:Evaluate the value of an arithmetic expression in Reverse Polish Notation.Valid operators are +, -, *, /. Each operand may be an integer or another expression.Some examples:

2014-04-22 16:33:25 559

原创 关于指针数组和数组指针的浅谈

在实际的运行情况下,非常容易对数组指针和指针数组进行混淆

2014-04-22 14:25:06 462

转载 leetcode题目--Reverse Words in a String解答

//题目内容//

2014-04-22 11:06:23 454

用表驱动法输出信息至结构体中,省略过多的输出语句、假设语句和集成语句。

用表驱动法从列表中提取各主要颜色的RGB值,经相应的函数处理后,输出至文件中。

2013-04-28

空空如也

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

TA关注的人

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