Skip to content

Commit 03b18e3

Browse files
author
openset
committed
Add: new
1 parent 1f7d2b9 commit 03b18e3

File tree

13 files changed

+36
-3
lines changed

13 files changed

+36
-3
lines changed

README.md

+3-2
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ LeetCode Problems' Solutions
5454

5555
| # | Title | Solution | Difficulty |
5656
| :-: | - | - | :-: |
57+
| <span id="1127">1127</span> | [User Purchase Platform](https://leetcode.com/problems/user-purchase-platform) 🔒 | [MySQL](https://github.com/openset/leetcode/tree/master/problems/user-purchase-platform) | Hard |
5758
| <span id="1126">1126</span> | [Active Businesses](https://leetcode.com/problems/active-businesses) 🔒 | [MySQL](https://github.com/openset/leetcode/tree/master/problems/active-businesses) | Medium |
5859
| <span id="1125">1125</span> | [Smallest Sufficient Team](https://leetcode.com/problems/smallest-sufficient-team "最小的必要团队") | [Go](https://github.com/openset/leetcode/tree/master/problems/smallest-sufficient-team) | Hard |
5960
| <span id="1124">1124</span> | [Longest Well-Performing Interval](https://leetcode.com/problems/longest-well-performing-interval "表现良好的最长时间段") | [Go](https://github.com/openset/leetcode/tree/master/problems/longest-well-performing-interval) | Medium |
@@ -64,8 +65,8 @@ LeetCode Problems' Solutions
6465
| <span id="1119">1119</span> | [Remove Vowels from a String](https://leetcode.com/problems/remove-vowels-from-a-string "删去字符串中的元音") 🔒 | [Go](https://github.com/openset/leetcode/tree/master/problems/remove-vowels-from-a-string) | Easy |
6566
| <span id="1118">1118</span> | [Number of Days in a Month](https://leetcode.com/problems/number-of-days-in-a-month "一月有多少天") 🔒 | [Go](https://github.com/openset/leetcode/tree/master/problems/number-of-days-in-a-month) | Easy |
6667
| <span id="1117">1117</span> | [Building H2O](https://leetcode.com/problems/building-h2o "H2O 生成") | [Go](https://github.com/openset/leetcode/tree/master/problems/building-h2o) | Hard |
67-
| <span id="1116">1116</span> | [Print Zero Even Odd](https://leetcode.com/problems/print-zero-even-odd) | [Go](https://github.com/openset/leetcode/tree/master/problems/print-zero-even-odd) | Medium |
68-
| <span id="1115">1115</span> | [Print FooBar Alternately](https://leetcode.com/problems/print-foobar-alternately) | [Go](https://github.com/openset/leetcode/tree/master/problems/print-foobar-alternately) | Medium |
68+
| <span id="1116">1116</span> | [Print Zero Even Odd](https://leetcode.com/problems/print-zero-even-odd "打印零与奇偶数") | [Go](https://github.com/openset/leetcode/tree/master/problems/print-zero-even-odd) | Medium |
69+
| <span id="1115">1115</span> | [Print FooBar Alternately](https://leetcode.com/problems/print-foobar-alternately "交替打印FooBar") | [Go](https://github.com/openset/leetcode/tree/master/problems/print-foobar-alternately) | Medium |
6970
| <span id="1114">1114</span> | [Print in Order](https://leetcode.com/problems/print-in-order "按序打印") | [Go](https://github.com/openset/leetcode/tree/master/problems/print-in-order) | Easy |
7071
| <span id="1113">1113</span> | [Reported Posts](https://leetcode.com/problems/reported-posts) 🔒 | [MySQL](https://github.com/openset/leetcode/tree/master/problems/reported-posts) | Easy |
7172
| <span id="1112">1112</span> | [Highest Grade For Each Student](https://leetcode.com/problems/highest-grade-for-each-student) 🔒 | [MySQL](https://github.com/openset/leetcode/tree/master/problems/highest-grade-for-each-student) | Medium |

problems/active-businesses/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88
[< Previous](https://github.com/openset/leetcode/tree/master/problems/smallest-sufficient-team "Smallest Sufficient Team")
99

10-
Next >
10+
[Next >](https://github.com/openset/leetcode/tree/master/problems/user-purchase-platform "User Purchase Platform")
1111

1212
## 1126. Active Businesses (Medium)
1313

+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
<!--|This file generated by command(leetcode description); DO NOT EDIT. |-->
2+
<!--+----------------------------------------------------------------------+-->
3+
<!--|@author Openset <openset.wang@gmail.com> |-->
4+
<!--|@link https://github.com/openset |-->
5+
<!--|@home https://github.com/openset/leetcode |-->
6+
<!--+----------------------------------------------------------------------+-->
7+
8+
[< Previous](https://github.com/openset/leetcode/tree/master/problems/active-businesses "Active Businesses")
9+
                
10+
Next >
11+
12+
## 1127. User Purchase Platform (Hard)
13+
14+
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
Create table If Not Exists Spending (user_id int, spend_date date, platform ENUM('desktop', 'mobile'), amount int);
2+
Truncate table Spending;
3+
insert into Spending (user_id, spend_date, platform, amount) values ('1', '2019-07-01', 'mobile', '100');
4+
insert into Spending (user_id, spend_date, platform, amount) values ('1', '2019-07-01', 'desktop', '100');
5+
insert into Spending (user_id, spend_date, platform, amount) values ('2', '2019-07-01', 'mobile', '100');
6+
insert into Spending (user_id, spend_date, platform, amount) values ('2', '2019-07-02', 'mobile', '100');
7+
insert into Spending (user_id, spend_date, platform, amount) values ('3', '2019-07-01', 'desktop', '100');
8+
insert into Spending (user_id, spend_date, platform, amount) values ('3', '2019-07-02', 'desktop', '100');

tag/array/README.md

+1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99

1010
| # | 题名 | 标签 | 难度 |
1111
| :-: | - | - | :-: |
12+
| 1122 | [数组的相对排序](https://github.com/openset/leetcode/tree/master/problems/relative-sort-array) | [[排序](https://github.com/openset/leetcode/tree/master/tag/sort/README.md)] [[数组](https://github.com/openset/leetcode/tree/master/tag/array/README.md)] | Easy |
1213
| 1099 | [小于 K 的两数之和](https://github.com/openset/leetcode/tree/master/problems/two-sum-less-than-k) 🔒 | [[数组](https://github.com/openset/leetcode/tree/master/tag/array/README.md)] | Easy |
1314
| 1089 | [复写零](https://github.com/openset/leetcode/tree/master/problems/duplicate-zeros) | [[数组](https://github.com/openset/leetcode/tree/master/tag/array/README.md)] | Easy |
1415
| 1086 | [前五科的均分](https://github.com/openset/leetcode/tree/master/problems/high-five) 🔒 | [[排序](https://github.com/openset/leetcode/tree/master/tag/sort/README.md)] [[数组](https://github.com/openset/leetcode/tree/master/tag/array/README.md)] [[哈希表](https://github.com/openset/leetcode/tree/master/tag/hash-table/README.md)] | Easy |

tag/bit-manipulation/README.md

+1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99

1010
| # | 题名 | 标签 | 难度 |
1111
| :-: | - | - | :-: |
12+
| 1125 | [最小的必要团队](https://github.com/openset/leetcode/tree/master/problems/smallest-sufficient-team) | [[位运算](https://github.com/openset/leetcode/tree/master/tag/bit-manipulation/README.md)] [[动态规划](https://github.com/openset/leetcode/tree/master/tag/dynamic-programming/README.md)] | Hard |
1213
| 898 | [子数组按位或操作](https://github.com/openset/leetcode/tree/master/problems/bitwise-ors-of-subarrays) | [[位运算](https://github.com/openset/leetcode/tree/master/tag/bit-manipulation/README.md)] [[动态规划](https://github.com/openset/leetcode/tree/master/tag/dynamic-programming/README.md)] | Medium |
1314
| 784 | [字母大小写全排列](https://github.com/openset/leetcode/tree/master/problems/letter-case-permutation) | [[位运算](https://github.com/openset/leetcode/tree/master/tag/bit-manipulation/README.md)] [[回溯算法](https://github.com/openset/leetcode/tree/master/tag/backtracking/README.md)] | Easy |
1415
| 762 | [二进制表示中质数个计算置位](https://github.com/openset/leetcode/tree/master/problems/prime-number-of-set-bits-in-binary-representation) | [[位运算](https://github.com/openset/leetcode/tree/master/tag/bit-manipulation/README.md)] | Easy |

tag/depth-first-search/README.md

+1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99

1010
| # | 题名 | 标签 | 难度 |
1111
| :-: | - | - | :-: |
12+
| 1123 | [最深叶节点的最近公共祖先](https://github.com/openset/leetcode/tree/master/problems/lowest-common-ancestor-of-deepest-leaves) | [[](https://github.com/openset/leetcode/tree/master/tag/tree/README.md)] [[深度优先搜索](https://github.com/openset/leetcode/tree/master/tag/depth-first-search/README.md)] | Medium |
1213
| 1102 | [得分最高的路径](https://github.com/openset/leetcode/tree/master/problems/path-with-maximum-minimum-value) 🔒 | [[深度优先搜索](https://github.com/openset/leetcode/tree/master/tag/depth-first-search/README.md)] [[并查集](https://github.com/openset/leetcode/tree/master/tag/union-find/README.md)] [[](https://github.com/openset/leetcode/tree/master/tag/graph/README.md)] | Medium |
1314
| 1080 | [根到叶路径上的不足节点](https://github.com/openset/leetcode/tree/master/problems/insufficient-nodes-in-root-to-leaf-paths) | [[深度优先搜索](https://github.com/openset/leetcode/tree/master/tag/depth-first-search/README.md)] | Medium |
1415
| 1061 | [按字典序排列最小的等效字符串](https://github.com/openset/leetcode/tree/master/problems/lexicographically-smallest-equivalent-string) 🔒 | [[深度优先搜索](https://github.com/openset/leetcode/tree/master/tag/depth-first-search/README.md)] [[并查集](https://github.com/openset/leetcode/tree/master/tag/union-find/README.md)] | Medium |

tag/dynamic-programming/README.md

+1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99

1010
| # | 题名 | 标签 | 难度 |
1111
| :-: | - | - | :-: |
12+
| 1125 | [最小的必要团队](https://github.com/openset/leetcode/tree/master/problems/smallest-sufficient-team) | [[位运算](https://github.com/openset/leetcode/tree/master/tag/bit-manipulation/README.md)] [[动态规划](https://github.com/openset/leetcode/tree/master/tag/dynamic-programming/README.md)] | Hard |
1213
| 1105 | [填充书架](https://github.com/openset/leetcode/tree/master/problems/filling-bookcase-shelves) | [[动态规划](https://github.com/openset/leetcode/tree/master/tag/dynamic-programming/README.md)] | Medium |
1314
| 1092 | [最短公共超序列](https://github.com/openset/leetcode/tree/master/problems/shortest-common-supersequence) | [[动态规划](https://github.com/openset/leetcode/tree/master/tag/dynamic-programming/README.md)] | Hard |
1415
| 1074 | [元素和为目标值的子矩阵数量](https://github.com/openset/leetcode/tree/master/problems/number-of-submatrices-that-sum-to-target) | [[数组](https://github.com/openset/leetcode/tree/master/tag/array/README.md)] [[动态规划](https://github.com/openset/leetcode/tree/master/tag/dynamic-programming/README.md)] [[Sliding Window](https://github.com/openset/leetcode/tree/master/tag/sliding-window/README.md)] | Hard |

tag/math/README.md

+1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99

1010
| # | 题名 | 标签 | 难度 |
1111
| :-: | - | - | :-: |
12+
| 1121 | [将数组分成几个递增序列](https://github.com/openset/leetcode/tree/master/problems/divide-array-into-increasing-sequences) 🔒 | [[数学](https://github.com/openset/leetcode/tree/master/tag/math/README.md)] | Hard |
1213
| 1104 | [二叉树寻路](https://github.com/openset/leetcode/tree/master/problems/path-in-zigzag-labelled-binary-tree) | [[](https://github.com/openset/leetcode/tree/master/tag/tree/README.md)] [[数学](https://github.com/openset/leetcode/tree/master/tag/math/README.md)] | Medium |
1314
| 1103 | [分糖果 II](https://github.com/openset/leetcode/tree/master/problems/distribute-candies-to-people) | [[数学](https://github.com/openset/leetcode/tree/master/tag/math/README.md)] | Easy |
1415
| 1093 | [大样本统计](https://github.com/openset/leetcode/tree/master/problems/statistics-from-a-large-sample) | [[数学](https://github.com/openset/leetcode/tree/master/tag/math/README.md)] [[双指针](https://github.com/openset/leetcode/tree/master/tag/two-pointers/README.md)] | Medium |

tag/sort/README.md

+1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99

1010
| # | 题名 | 标签 | 难度 |
1111
| :-: | - | - | :-: |
12+
| 1122 | [数组的相对排序](https://github.com/openset/leetcode/tree/master/problems/relative-sort-array) | [[排序](https://github.com/openset/leetcode/tree/master/tag/sort/README.md)] [[数组](https://github.com/openset/leetcode/tree/master/tag/array/README.md)] | Easy |
1213
| 1086 | [前五科的均分](https://github.com/openset/leetcode/tree/master/problems/high-five) 🔒 | [[排序](https://github.com/openset/leetcode/tree/master/tag/sort/README.md)] [[数组](https://github.com/openset/leetcode/tree/master/tag/array/README.md)] [[哈希表](https://github.com/openset/leetcode/tree/master/tag/hash-table/README.md)] | Easy |
1314
| 1057 | [校园自行车分配](https://github.com/openset/leetcode/tree/master/problems/campus-bikes) 🔒 | [[贪心算法](https://github.com/openset/leetcode/tree/master/tag/greedy/README.md)] [[排序](https://github.com/openset/leetcode/tree/master/tag/sort/README.md)] | Medium |
1415
| 1054 | [距离相等的条形码](https://github.com/openset/leetcode/tree/master/problems/distant-barcodes) | [[](https://github.com/openset/leetcode/tree/master/tag/heap/README.md)] [[排序](https://github.com/openset/leetcode/tree/master/tag/sort/README.md)] | Medium |

tag/stack/README.md

+1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99

1010
| # | 题名 | 标签 | 难度 |
1111
| :-: | - | - | :-: |
12+
| 1124 | [表现良好的最长时间段](https://github.com/openset/leetcode/tree/master/problems/longest-well-performing-interval) | [[](https://github.com/openset/leetcode/tree/master/tag/stack/README.md)] | Medium |
1213
| 1063 | [有效子数组的数目](https://github.com/openset/leetcode/tree/master/problems/number-of-valid-subarrays) 🔒 | [[](https://github.com/openset/leetcode/tree/master/tag/stack/README.md)] | Hard |
1314
| 1047 | [删除字符串中的所有相邻重复项](https://github.com/openset/leetcode/tree/master/problems/remove-all-adjacent-duplicates-in-string) | [[](https://github.com/openset/leetcode/tree/master/tag/stack/README.md)] | Easy |
1415
| 1021 | [删除最外层的括号](https://github.com/openset/leetcode/tree/master/problems/remove-outermost-parentheses) | [[](https://github.com/openset/leetcode/tree/master/tag/stack/README.md)] | Easy |

tag/string/README.md

+1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99

1010
| # | 题名 | 标签 | 难度 |
1111
| :-: | - | - | :-: |
12+
| 1119 | [删去字符串中的元音](https://github.com/openset/leetcode/tree/master/problems/remove-vowels-from-a-string) 🔒 | [[字符串](https://github.com/openset/leetcode/tree/master/tag/string/README.md)] | Easy |
1213
| 1106 | [解析布尔表达式](https://github.com/openset/leetcode/tree/master/problems/parsing-a-boolean-expression) | [[字符串](https://github.com/openset/leetcode/tree/master/tag/string/README.md)] | Hard |
1314
| 1100 | [长度为 K 的无重复字符子串](https://github.com/openset/leetcode/tree/master/problems/find-k-length-substrings-with-no-repeated-characters) 🔒 | [[字符串](https://github.com/openset/leetcode/tree/master/tag/string/README.md)] [[Sliding Window](https://github.com/openset/leetcode/tree/master/tag/sliding-window/README.md)] | Medium |
1415
| 1096 | [花括号展开 II](https://github.com/openset/leetcode/tree/master/problems/brace-expansion-ii) | [[字符串](https://github.com/openset/leetcode/tree/master/tag/string/README.md)] | Hard |

tag/tree/README.md

+2
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,8 @@
99

1010
| # | 题名 | 标签 | 难度 |
1111
| :-: | - | - | :-: |
12+
| 1123 | [最深叶节点的最近公共祖先](https://github.com/openset/leetcode/tree/master/problems/lowest-common-ancestor-of-deepest-leaves) | [[](https://github.com/openset/leetcode/tree/master/tag/tree/README.md)] [[深度优先搜索](https://github.com/openset/leetcode/tree/master/tag/depth-first-search/README.md)] | Medium |
13+
| 1120 | [子树的最大平均值](https://github.com/openset/leetcode/tree/master/problems/maximum-average-subtree) 🔒 | [[](https://github.com/openset/leetcode/tree/master/tag/tree/README.md)] | Medium |
1214
| 1104 | [二叉树寻路](https://github.com/openset/leetcode/tree/master/problems/path-in-zigzag-labelled-binary-tree) | [[](https://github.com/openset/leetcode/tree/master/tag/tree/README.md)] [[数学](https://github.com/openset/leetcode/tree/master/tag/math/README.md)] | Medium |
1315
| 1028 | [从先序遍历还原二叉树](https://github.com/openset/leetcode/tree/master/problems/recover-a-tree-from-preorder-traversal) | [[](https://github.com/openset/leetcode/tree/master/tag/tree/README.md)] [[深度优先搜索](https://github.com/openset/leetcode/tree/master/tag/depth-first-search/README.md)] | Hard |
1416
| 1026 | [节点与其祖先之间的最大差值](https://github.com/openset/leetcode/tree/master/problems/maximum-difference-between-node-and-ancestor) | [[](https://github.com/openset/leetcode/tree/master/tag/tree/README.md)] [[深度优先搜索](https://github.com/openset/leetcode/tree/master/tag/depth-first-search/README.md)] | Medium |

0 commit comments

Comments
 (0)