题目描述 Given a complete binary tree, count the number of nodes. Definition of a complete binary tree from Wikipe…
标签:LeetCode题目解答
46. Permutations 排列数
46. Permutations 题目 Given a collection of distinct numbers, return all possible permutations. For example, [1,…
[LeetCode] Network Delay Time 网络延迟时间
There are N network nodes, labelled 1 to N. Given times, a list of travel…
LeetCode | Substring with Concatenation of All Words
题目: You are given a string, S, and a list of words, L, that are all of the same length. Find all sta…
[LeetCode] Intersection of Two Arrays II 两个数组相交之二
Given two arrays, write a function to compute their intersection. Example 1: Input: nums1 = [1,2,2,1], …
[LeetCode] Find Smallest Letter Greater Than Target 找比目标值大的最小字母
Given a list of sorted characters letters containing only lowercase letters, and given a targ…
115. Distinct Subsequences
欢迎fork and star:Nowcoder-Repository-github 115. Distinct Subsequences 题目 Given a string S and a string T, coun…
[LeetCode] First Missing Positive 首个缺失的正数
Given an unsorted integer array, find the smallest missing positive integer. Example 1: Input: [1,…
[LeetCode] Rotate Function 旋转函数
Given an array of integers A and let n to be its length. Assume Bk to be …
[LeetCode] 4Sum II 四数之和之二
Given four lists A, B, C, D of integer values, compute how many tuples (i, j, k, l) there are…
【leetcode】29. Divide Two Integers 不能使用乘除法的整数除法
1. 题目 Divide two integers without using multiplication, division and mod operator. If it is overflow, return M…
【Leetcode】3. Longest Substring Without RepeatingCharacters无重最长子串
1. 题目 Given a string, find the length of the longest substring without repeating characters. Examples: Given &…