Timo66

  博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理

07 2015 档案

摘要:Binary search in sorted ArrayQuestion 1Median of Two Sorted ArraysThere are two sorted arraysnums1andnums2of size m and n respectively. Find the media... 阅读全文
posted @ 2015-07-30 09:59 Timo66 阅读(289) 评论(0) 推荐(0) 编辑

摘要:substringQuestion 1Implement strStr()Implement strStr().Returns the index of the first occurrence of needle in haystack, or -1 if needle is not part o... 阅读全文
posted @ 2015-07-24 22:19 Timo66 阅读(217) 评论(0) 推荐(0) 编辑

摘要:Add / Divide / Multiply / Power / Plus / SqrtQuestion 1Add Two NumbersYou are given two linked lists representing two non-negative numbers. The digits... 阅读全文
posted @ 2015-07-22 09:09 Timo66 阅读(284) 评论(0) 推荐(0) 编辑

摘要:n-sum problemQuestion 2Two SumGiven an array of integers, find two numbers such that they add up to a specific target number.The function twoSum shoul... 阅读全文
posted @ 2015-07-21 21:42 Timo66 阅读(172) 评论(0) 推荐(0) 编辑

摘要:Question 1Add BinaryGiven two binary strings, return their sum (also a binary string).For example,a ="11"b ="1"Return"100".Firslty I wirte a very dire... 阅读全文
posted @ 2015-07-20 22:04 Timo66 阅读(176) 评论(0) 推荐(0) 编辑

摘要:Question1Power of TwoGiven an integer, write a function to determine if it is a power of two.This question is pretty simple. If a number is a power of... 阅读全文
posted @ 2015-07-20 11:06 Timo66 阅读(163) 评论(0) 推荐(0) 编辑

摘要:Question 1Reverse IntegerReverse digits of an integer.Example1:x = 123, return 321Example2:x = -123, return -321We need to consider a lot of cases of ... 阅读全文
posted @ 2015-07-18 23:52 Timo66 阅读(212) 评论(0) 推荐(0) 编辑

摘要:Question 1Integer to RomanGiven an integer, convert it to a roman numeral.Input is guaranteed to be within the range from 1 to 3999What we need to not... 阅读全文
posted @ 2015-07-18 02:16 Timo66 阅读(151) 评论(0) 推荐(0) 编辑

摘要:Question 1Roman to IntegerGiven a roman numeral, convert it to an integer.Input is guaranteed to be within the range from 1 to 3999.This problem is no... 阅读全文
posted @ 2015-07-17 02:52 Timo66 阅读(173) 评论(0) 推荐(0) 编辑

摘要:Form today on, I changed to Math module question.Question 1String to Integer (atoi)Implementatoito convert a string to an integer.Remember one thing h... 阅读全文
posted @ 2015-07-15 23:25 Timo66 阅读(149) 评论(0) 推荐(0) 编辑

摘要:Question 1.Convert Sorted Array to Binary Search TreeGiven an array where elements are sorted in ascending order, convert it to a height balanced BST.... 阅读全文
posted @ 2015-07-14 22:20 Timo66 阅读(131) 评论(0) 推荐(0) 编辑

摘要:Sum Root to Leaf NumbersGiven a binary tree containing digits from0-9only, each root-to-leaf path could represent a number.An example is the root-to-l... 阅读全文
posted @ 2015-07-14 08:38 Timo66 阅读(136) 评论(0) 推荐(0) 编辑

摘要:Path Sum IIGiven a binary tree and a sum, find all root-to-leaf paths where each path's sum equals the given sum.For example:Given the below binary tr... 阅读全文
posted @ 2015-07-13 01:17 Timo66 阅读(170) 评论(0) 推荐(0) 编辑

摘要:Minimum Depth of Binary TreeGiven a binary tree, find its minimum depth.The minimum depth is the number of nodes along the shortest path from the root... 阅读全文
posted @ 2015-07-12 22:21 Timo66 阅读(139) 评论(0) 推荐(0) 编辑

摘要:Balanced Binary TreeGiven a binary tree, determine if it is height-balanced.For this problem, a height-balanced binary tree is defined as a binary tre... 阅读全文
posted @ 2015-07-11 22:04 Timo66 阅读(172) 评论(0) 推荐(0) 编辑

摘要:Maximum Depth of Binary Tree (DFS, TREE)Given a binary tree, find its maximum depth.The maximum depth is the number of nodes along the longest path fr... 阅读全文
posted @ 2015-07-10 11:09 Timo66 阅读(326) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示