- 博客(9)
- 收藏
- 关注
转载 [LeetCode] Shortest Palindrome 最短回文串
Given a string S, you are allowed to convert it to a palindrome by adding characters in front of it. Find and return the shortest palindrome you can find by performing this transformation.For exam
2015-09-18 06:27:49 1110
转载 Contains Duplicate III
Given an array of integers, find out whether there are two distinct indices i and j in the array such that the difference between nums[i] and nums[j] is at most t and the difference between i and
2015-09-18 04:21:41 780
转载 Contains Duplicate III
Contains Duplicate IIIGiven an array of integers, find out whether there are two distinct indices i and j in the array such that the difference between nums[i] and nums[j] is at most t and the d
2015-09-18 04:15:27 687
转载 Count Complete Tree Nodes
http://bookshadow.com/weblog/2015/06/06/leetcode-count-complete-tree-nodes/
2015-09-18 03:55:15 632
转载 eetCode] Basic Calculator & Basic Calculator II Basic Calculator
Basic CalculatorImplement a basic calculator to evaluate a simple expression string.The expression string may contain open ( and closing parentheses ), the plus + or minus sign -, non-negative
2015-09-18 03:29:11 862
转载 Leetcode: Product of Array Except Self (60ms) analysis and solution
Problem:Given an array of n integers where n > 1, nums, return an array output such that output[i] is equal to the product of all the elements ofnums except nums[i].Solve it withou
2015-09-17 23:13:20 563
转载 Implement Queue using Stacks
A queue can be implemented using two stacks. Let queue to be implemented be q and stacks used to implement q be stack1 and stack2. q can be implemented in two ways:Method 1 (By making enQueue oper
2015-09-17 22:36:50 664
转载 SINGLE NUMBER I & II & III
Single Number I :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
2015-09-17 22:26:55 2289 3
转载 Implement stack using a queue
The puzzle is to implement basic stack operations with using only basic queue operations. That is, a queue object is given, we need construct a wrapper for the stack functions, push, pop, which will o
2015-09-09 03:21:26 854
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人