上一页 1 ··· 10 11 12 13 14 15 16 17 18 ··· 22 下一页
摘要: Given a binary tree, return the inorder traversal of its nodes' values. For example:Given binary tree [1,null,2,3], return [1,3,2]. 阅读全文
posted @ 2016-07-07 10:07 YuriFLAG 阅读(125) 评论(0) 推荐(0)
摘要: Given inorder and postorder traversal of a tree, construct the binary tree. Note:You may assume that duplicates do not exist in the tree. 思路:后序遍历中最后一个 阅读全文
posted @ 2016-07-06 10:10 YuriFLAG 阅读(130) 评论(0) 推荐(0)
摘要: Given an integer n, count the total number of digit 1 appearing in all non-negative integers less than or equal to n. For example:Given n = 13,Return 阅读全文
posted @ 2016-06-26 17:04 YuriFLAG 阅读(122) 评论(0) 推荐(0)
摘要: Given a binary tree containing digits from 0-9 only, each root-to-leaf path could represent a number. An example is the root-to-leaf path 1->2->3 whic 阅读全文
posted @ 2016-06-26 10:21 YuriFLAG 阅读(122) 评论(0) 推荐(0)
摘要: Given two arrays, write a function to compute their intersection. Example:Given nums1 = [1, 2, 2, 1], nums2 = [2, 2], return [2, 2]. Note: Each elemen 阅读全文
posted @ 2016-06-14 08:33 YuriFLAG 阅读(118) 评论(0) 推荐(0)
摘要: Given two numbers represented as strings, return multiplication of the numbers as a string. Note: The numbers can be arbitrarily large and are non-neg 阅读全文
posted @ 2016-06-07 09:23 YuriFLAG 阅读(123) 评论(0) 推荐(0)
摘要: Given a string, find all permutations of it without duplicates. Example Given "abb", return ["abb", "bab", "bba"]. Given "aabb", return ["aabb", "abab 阅读全文
posted @ 2016-06-05 09:19 YuriFLAG 阅读(190) 评论(0) 推荐(0)
摘要: Given an array of strings, return all groups of strings that are anagrams. All inputs will be in lower-case Example Given ["lint", "intl", "inlt", "co 阅读全文
posted @ 2016-06-03 14:39 YuriFLAG 阅读(128) 评论(0) 推荐(0)
摘要: Given two binary strings, return their sum (also a binary string). Example a = 11 b = 1 Return 100 1 public class Solution { 2 /** 3 * @param a a numb 阅读全文
posted @ 2016-06-03 08:51 YuriFLAG 阅读(90) 评论(0) 推荐(0)
摘要: Given a string which contains only letters. Sort it by lower case first and upper case second. Example For "abAcD", a reasonable answer is "acbAD" 与将负 阅读全文
posted @ 2016-06-03 08:20 YuriFLAG 阅读(133) 评论(0) 推荐(0)
上一页 1 ··· 10 11 12 13 14 15 16 17 18 ··· 22 下一页