题目: Given a set of distinct integers, S, return all possible subsets. Note: Elements in a subset must be …
分类:LeetCode题目解答
LeetCode之Graph题目汇总
Course Schedule There are a total of n courses you have to take, labeled from 0 to n …
LeetCode 234 Palindrome Linked List
题目描述 Given a singly linked list, determine if it is a palindrome. Follow up: Could you do it in O(n) time and …
[Leetcode] Unique Substrings in Wraparound String 循环字符串中的唯一子串
Unique Substrings in Wraparound String Consider the string s to be the infinite wraparound string of "abcdefgh…
LeetCode 2. Add Two Numbers
题目 You are given two non-empty linked lists representing two non-negative integers. The digits are stored in r…
105. Construct Binary Tree from Preorder and Inorder Traversal
欢迎fork and star:Nowcoder-Repository-github 105. Construct Binary Tree from Preorder and Inorder Traversal 题目 G…
[LeetCode] Can I Win 我能赢吗
In the “100 game,” two players take turns adding, to a running total, any integer from 1..1…
LeetCode 026 Remove Duplicates from Sorted Array
题目描述 Given a sorted array, remove the duplicates in place such that each element appear only once and return t…
199. Binary Tree Right Side View
Given a binary tree, imagine yourself standing on the right side of it, return the values of the nodes you can…
LeetCode 275 H-Index II
题目描述 Follow up for H-Index: What if the citations array is sorted in ascending order? Could you optimize your …
【leetcode】刷题暂告一个段落
近一年没有写代码了,手痒无聊,集中刷了近一百题,前一半按序全部做了,后面的挑了有意思的做,一眼看起来太简单的且重复类型的就忽略了。最近挑的题,发现没有了自测按钮,不太方便。暂时不再刷题了。开启新的一章,学习“机器学习”,…
[LeetCode] Sequence Reconstruction 序列重建
Check whether the original sequence org can be uniquely reconstructed from the sequences in seqs. The o…