上一页 1 ··· 19 20 21 22 23 24 25 26 27 ··· 31 下一页
摘要: 题目: Given an array containing n distinct numbers taken from 0, 1, 2, ..., n, find the one that is missing from the array. For example,Given nums = [0, 阅读全文
posted @ 2017-03-06 06:20 panini 阅读(113) 评论(0) 推荐(0) 编辑
摘要: 题目: Given a string, determine if a permutation of the string could form a palindrome. For example,"code" -> False, "aab" -> True, "carerac" -> True. H 阅读全文
posted @ 2017-03-06 06:14 panini 阅读(130) 评论(0) 推荐(0) 编辑
摘要: 题目: Write a program to check whether a given number is an ugly number. Ugly numbers are positive numbers whose prime factors only include 2, 3, 5. For 阅读全文
posted @ 2017-03-06 06:01 panini 阅读(77) 评论(0) 推荐(0) 编辑
摘要: 题目: Given a non-negative integer num, repeatedly add all its digits until the result has only one digit. For example: Given num = 38, the process is l 阅读全文
posted @ 2017-03-05 12:12 panini 阅读(112) 评论(0) 推荐(0) 编辑
摘要: 题目: Given a binary tree, return all root-to-leaf paths. For example, given the following binary tree: All root-to-leaf paths are: 链接: http://leetcode. 阅读全文
posted @ 2017-03-05 11:53 panini 阅读(129) 评论(0) 推荐(0) 编辑
摘要: 题目: There are a row of n houses, each house can be painted with one of the three colors: red, blue or green. The cost of painting each house with a ce 阅读全文
posted @ 2017-03-05 09:24 panini 阅读(188) 评论(0) 推荐(0) 编辑
摘要: 题目: Given an array of meeting time intervals consisting of start and end times [[s1,e1],[s2,e2],...] (si < ei), determine if a person could attend all 阅读全文
posted @ 2017-03-05 08:57 panini 阅读(132) 评论(0) 推荐(0) 编辑
摘要: 题目: A strobogrammatic number is a number that looks the same when rotated 180 degrees (looked at upside down). Write a function to determine if a numb 阅读全文
posted @ 2017-03-03 07:41 panini 阅读(155) 评论(0) 推荐(0) 编辑
摘要: 题目: Given a list of words and two words word1 and word2, return the shortest distance between these two words in the list. For example,Assume that wor 阅读全文
posted @ 2017-03-03 07:17 panini 阅读(114) 评论(0) 推荐(0) 编辑
摘要: 题目: Given two strings s and t, write a function to determine if t is an anagram of s. For example,s = "anagram", t = "nagaram", return true.s = "rat", 阅读全文
posted @ 2017-03-03 06:58 panini 阅读(128) 评论(0) 推荐(0) 编辑
上一页 1 ··· 19 20 21 22 23 24 25 26 27 ··· 31 下一页