上一页 1 ··· 31 32 33 34 35 36 37 38 39 ··· 53 下一页
摘要: Given a non-empty array of integers, return the k most frequent elements. For example,Given [1,1,1,2,2,3] and k = 2, return [1,2]. 分析: http://blog.csd 阅读全文
posted @ 2016-07-27 01:24 北叶青藤 阅读(208) 评论(0) 推荐(0) 编辑
摘要: Given an Android 3x3 key lock screen and two integers m and n, where 1 ≤ m ≤ n ≤ 9, count the total number of unlock patterns of the Android lock scre 阅读全文
posted @ 2016-07-26 23:43 北叶青藤 阅读(307) 评论(0) 推荐(0) 编辑
摘要: Given a non-negative integer n, count all numbers with unique digits, x, where 0 ≤ x < 10n. Example:Given n = 2, return 91. (The answer should be the 阅读全文
posted @ 2016-07-26 12:38 北叶青藤 阅读(162) 评论(0) 推荐(0) 编辑
摘要: Given a positive integer num, write a function which returns True if num is a perfect square else False. Note: Do not use any built-in library functio 阅读全文
posted @ 2016-07-26 10:37 北叶青藤 阅读(145) 评论(0) 推荐(0) 编辑
摘要: Given a binary tree, collect a tree's nodes as if you were doing this: Collect and remove all leaves, repeat until the tree is empty. Example:Given bi 阅读全文
posted @ 2016-07-26 01:03 北叶青藤 阅读(201) 评论(0) 推荐(0) 编辑
摘要: Given a non-negative number represented as a singly linked list of digits, plus one to the number. The digits are stored such that the most significan 阅读全文
posted @ 2016-07-26 00:25 北叶青藤 阅读(195) 评论(0) 推荐(0) 编辑
摘要: Given n balloons, indexed from 0 to n-1. Each balloon is painted with a number on it represented by array nums. You are asked to burst all the balloon 阅读全文
posted @ 2016-07-24 04:29 北叶青藤 阅读(228) 评论(0) 推荐(0) 编辑
摘要: The size of the hash table is not determinate at the very beginning. If the total size of keys is too large (e.g. size >= capacity / 10), we should do 阅读全文
posted @ 2016-07-23 05:53 北叶青藤 阅读(352) 评论(0) 推荐(0) 编辑
摘要: Implement function atoi to convert a string to an integer. If no valid conversion could be performed, a zero value is returned. If the correct value i 阅读全文
posted @ 2016-07-23 05:22 北叶青藤 阅读(215) 评论(0) 推荐(0) 编辑
摘要: Calculate the a^n % b where a, b and n are all 32bit integers. Calculate the a^n % b where a, b and n are all 32bit integers. Calculate the a^n % b wh 阅读全文
posted @ 2016-07-23 04:57 北叶青藤 阅读(252) 评论(0) 推荐(0) 编辑
上一页 1 ··· 31 32 33 34 35 36 37 38 39 ··· 53 下一页