摘要:
Given inorder and postorder traversal of a tree, construct the binary tree. Note:You may assume that duplicates do not exist in the tree. 思路:后序遍历中最后一个 阅读全文
摘要:
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 阅读全文
摘要:
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 阅读全文
摘要:
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 阅读全文
摘要:
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 阅读全文
摘要:
Given a string, find all permutations of it without duplicates. Example Given "abb", return ["abb", "bab", "bba"]. Given "aabb", return ["aabb", "abab 阅读全文
摘要:
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 阅读全文
摘要:
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 阅读全文
摘要:
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" 与将负 阅读全文