摘要:
Implement the following operations of a queue using stacks.push(x) -- Push element x to the back of queue.pop() -- Removes the element from in front o... 阅读全文
posted @ 2016-01-12 09:11
Hygeia
阅读(139)
评论(0)
推荐(0)
摘要:
Given an integer, write a function to determine if it is a power of three.Follow up:Could you do it without using any loop / recursion?public class So... 阅读全文
posted @ 2016-01-12 08:50
Hygeia
阅读(109)
评论(0)
推荐(0)
摘要:
Given an arraynumsand a target valuek, find the maximum length of a subarray that sums tok. If there isn't one, return 0 instead.Example 1:Givennums=[... 阅读全文
posted @ 2016-01-12 06:47
Hygeia
阅读(605)
评论(0)
推荐(0)
摘要:
A peak element is an element that is greater than its neighbors.Given an input array wherenum[i] ≠ num[i+1], find a peak element and return its index.... 阅读全文
posted @ 2016-01-12 06:25
Hygeia
阅读(135)
评论(0)
推荐(0)

浙公网安备 33010602011771号