上一页 1 ··· 19 20 21 22 23 24 25 26 27 ··· 49 下一页
摘要: Reverse bits of a given 32 bits unsigned integer. For example, given input 43261596 (represented in binary as 00000010100101000001111010011100), retur 阅读全文
posted @ 2017-10-25 10:30 daniel456 阅读(89) 评论(0) 推荐(0)
摘要: Evaluate the value of an arithmetic expression in Reverse Polish Notation. Valid operators are +, -, *, /. Each operand may be an integer or another e 阅读全文
posted @ 2017-10-25 10:24 daniel456 阅读(134) 评论(0) 推荐(0)
摘要: Design a stack that supports push, pop, top, and retrieving the minimum element in constant time. push(x) -- Push element x onto stack. pop() -- Remov 阅读全文
posted @ 2017-10-25 10:20 daniel456 阅读(158) 评论(0) 推荐(0)
摘要: One way to serialize a binary tree is to use pre-order traversal. When we encounter a non-null node, we record the node's value. If it is a null node, 阅读全文
posted @ 2017-10-24 21:53 daniel456 阅读(180) 评论(0) 推荐(0)
摘要: Given a non-negative integer num represented as a string, remove k digits from the number so that the new number is the smallest possible. Note: The l 阅读全文
posted @ 2017-10-24 21:43 daniel456 阅读(208) 评论(0) 推荐(0)
摘要: Given a sequence of n integers a1, a2, ..., an, a 132 pattern is a subsequence ai, aj, ak such that i < j < k and ai < ak < aj. Design an algorithm th 阅读全文
posted @ 2017-10-24 21:35 daniel456 阅读(212) 评论(0) 推荐(0)
摘要: You are given two arrays (without duplicates) nums1 and nums2 where nums1’s elements are subset of nums2. Find all the next greater numbers for nums1' 阅读全文
posted @ 2017-10-24 21:23 daniel456 阅读(128) 评论(0) 推荐(0)
摘要: Given a circular array (the next element of the last element is the first element of the array), print the Next Greater Number for every element. The 阅读全文
posted @ 2017-10-24 21:13 daniel456 阅读(126) 评论(0) 推荐(0)
摘要: Given a nested list of integers, implement an iterator to flatten it. Each element is either an integer, or a list -- whose elements may also be integ 阅读全文
posted @ 2017-10-24 20:57 daniel456 阅读(118) 评论(0) 推荐(0)
摘要: 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 阅读全文
posted @ 2017-10-24 20:53 daniel456 阅读(74) 评论(0) 推荐(0)
上一页 1 ··· 19 20 21 22 23 24 25 26 27 ··· 49 下一页