07 2017 档案
摘要:In LeetCode Store, there are n items to sell. Each item has a price. However, there are some special offers, and a special offer consists of one or mo
阅读全文
摘要:Given a non-empty binary tree, return the average value of the nodes on each level in the form of an array. Example 1: Input: 3 / \ 9 20 / \ 15 7 Outp
阅读全文
摘要:Given the running logs of n functions that are executed in a nonpreemptive single threaded CPU, find the exclusive time of these functions. Each funct
阅读全文
摘要:You are given several logs that each log contains a unique id and timestamp. Timestamp is a string that has the following format: Year:Month:Day:Hour:
阅读全文
摘要:In combinatorial mathematics, a derangement is a permutation of the elements of a set, such that no element appears in its original position. There's
阅读全文
摘要:You have k lists of sorted integers in ascending order. Find the smallest range that includes at least one number from each of the k lists. We define
阅读全文
摘要:Given a non-negative integer c, your task is to decide whether there're two integers a and b such that a2 + b2 = c. Example 1: Example 2: 这道题让我们求一个数是否
阅读全文
摘要:Your task is to design the basic function of Excel and implement the function of sum formula. Specifically, you need to implement the following functi
阅读全文
摘要:Given two words word1 and word2, find the minimum number of steps required to make word1 and word2 the same, where in each step you can delete one cha
阅读全文
摘要:Given n processes, each process has a unique PID (process id) and its PPID (parent process id). Each process only has one parent process, but may have
阅读全文
摘要:There are n different online courses numbered from 1 to n. Each course has some duration(course length) tand closed on dth day. A course should be tak
阅读全文
摘要:Given two integers n and k, find how many different arrays consist of numbers from 1 to n such that there are exactly k inverse pairs. We define an in
阅读全文