Skip to content

Commit 8e6eeaf

Browse files
authored
chore: update lc problems (#1795)
1 parent eff72ba commit 8e6eeaf

File tree

22 files changed

+94
-103
lines changed

22 files changed

+94
-103
lines changed

solution/0000-0099/0074.Search a 2D Matrix/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
<p>给你一个满足下述两条属性的 <code>m x n</code> 整数矩阵:</p>
1010

1111
<ul>
12-
<li>每行中的整数从左到右按非递减顺序排列。</li>
12+
<li>每行中的整数从左到右按非严格递增顺序排列。</li>
1313
<li>每行的第一个整数大于前一行的最后一个整数。</li>
1414
</ul>
1515

solution/0100-0199/0138.Copy List with Random Pointer/README.md

-2
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,6 @@
6262
<li><code>Node.random</code>&nbsp;为&nbsp;<code>null</code> 或指向链表中的节点。</li>
6363
</ul>
6464

65-
<p>注意:本题与主站 138 题相同:<a href="https://leetcode.cn/problems/copy-list-with-random-pointer/" rel="noopener noreferrer" target="_blank">https://leetcode.cn/problems/copy-list-with-random-pointer/</a></p>
66-
6765
<p>&nbsp;</p>
6866

6967
## 解法

solution/0600-0699/0683.K Empty Slots/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
<p><code>n</code>&nbsp;个灯泡排成一行,编号从 <code>1</code> 到<meta charset="UTF-8" />&nbsp;<code>n</code>&nbsp;。最初,所有灯泡都关闭。每天&nbsp;<strong>只打开一个</strong>&nbsp;灯泡,直到<meta charset="UTF-8" />&nbsp;<code>n</code>&nbsp;天后所有灯泡都打开。</p>
1010

11-
<p>给你一个长度为<meta charset="UTF-8" />&nbsp;<code>n</code>&nbsp;的灯泡数组 <code>blubs</code> ,其中 <code>bulls[i] = x</code> 意味着在第 <code>(i+1)</code> 天,我们会把在位置 <code>x</code> 的灯泡打开,其中 <code>i</code> <strong>从 0 开始</strong>,<code>x</code> <strong>从 1 开始</strong>。</p>
11+
<p>给你一个长度为<meta charset="UTF-8" />&nbsp;<code>n</code>&nbsp;的灯泡数组 <code>blubs</code> ,其中 <code>bulbs[i] = x</code> 意味着在第 <code>(i+1)</code> 天,我们会把在位置 <code>x</code> 的灯泡打开,其中 <code>i</code> <strong>从 0 开始</strong>,<code>x</code> <strong>从 1 开始</strong>。</p>
1212

1313
<p>给你一个整数<meta charset="UTF-8" />&nbsp;<code>k</code>&nbsp;,请返回<em>恰好有两个打开的灯泡,且它们中间 <strong>正好</strong> 有<meta charset="UTF-8" />&nbsp;<code>k</code>&nbsp;&nbsp;<strong>全部关闭的</strong> 灯泡的 <strong>最小的天数</strong> </em>。<em>如果不存在这种情况,返回 <code>-1</code> 。</em></p>
1414

solution/0900-0999/0981.Time Based Key-Value Store/README_EN.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
<ul>
1212
<li><code>TimeMap()</code> Initializes the object of the data structure.</li>
13-
<li><code>void set(String key, String value, int timestamp)</code> Stores the key <code>key</code> with the value <code>value </code>at the given time <code>timestamp</code>.</li>
13+
<li><code>void set(String key, String value, int timestamp)</code> Stores the key <code>key</code> with the value <code>value</code> at the given time <code>timestamp</code>.</li>
1414
<li><code>String get(String key, int timestamp)</code> Returns a value such that <code>set</code> was called previously, with <code>timestamp_prev &lt;= timestamp</code>. If there are multiple such values, it returns the value associated with the largest <code>timestamp_prev</code>. If there are no values, it returns <code>&quot;&quot;</code>.</li>
1515
</ul>
1616

solution/1100-1199/1159.Market Analysis II/README_EN.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -53,11 +53,11 @@ item_id is the primary key (column with unique values) of this table.
5353

5454
<p>&nbsp;</p>
5555

56-
<p>Write a solution to find for each user whether the brand of the second item (by date) they sold is their favorite brand. If a user sold less than two items, report the answer for that user as no. It is guaranteed that no seller sold more than one item in a day.</p>
56+
<p>Write a solution&nbsp;to find for each user, the join date and the number of orders they made as a buyer in <code>2019</code>.</p>
5757

5858
<p>Return the result table in <strong>any order</strong>.</p>
5959

60-
<p>The result format is in the following example.</p>
60+
<p>The&nbsp;result format is in the following example.</p>
6161

6262
<p>&nbsp;</p>
6363
<p><strong class="example">Example 1:</strong></p>

solution/1300-1399/1349.Maximum Students Taking Exam/README_EN.md

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

77
<p>Given a <code>m&nbsp;* n</code>&nbsp;matrix <code>seats</code>&nbsp;&nbsp;that represent seats distributions&nbsp;in a classroom.&nbsp;If a seat&nbsp;is&nbsp;broken, it is denoted by <code>&#39;#&#39;</code> character otherwise it is denoted by a <code>&#39;.&#39;</code> character.</p>
88

9-
<p>Students can see the answers of those sitting next to the left, right, upper left and upper right, but he cannot see the answers of the student sitting&nbsp;directly in front or behind him. Return the <strong>maximum </strong>number of students that can take the exam together&nbsp;without any cheating being possible..</p>
9+
<p>Students can see the answers of those sitting next to the left, right, upper left and upper right, but he cannot see the answers of the student sitting&nbsp;directly in front or behind him. Return the <strong>maximum </strong>number of students that can take the exam together&nbsp;without any cheating being possible.</p>
1010

1111
<p>Students must be placed in seats in good condition.</p>
1212

solution/1400-1499/1409.Queries on a Permutation With Key/README.md

+16-13
Original file line numberDiff line numberDiff line change
@@ -6,38 +6,41 @@
66

77
<!-- 这里写题目描述 -->
88

9-
<p>给你一个待查数组 <code>queries</code> ,数组中的元素为 <code>1</code> 到 <code>m</code> 之间的正整数。 请你根据以下规则处理所有待查项 <code>queries[i]</code>(从 <code>i=0</code> 到 <code>i=queries.length-1</code>):</p>
9+
<p>给定一个正整数数组&nbsp;<code>queries</code> ,其取值范围在&nbsp;<code>1</code> 到 <code>m</code> 之间。 请你根据以下规则按顺序处理所有&nbsp;<code>queries[i]</code>(从 <code>i=0</code> 到 <code>i=queries.length-1</code>):</p>
1010

1111
<ul>
12-
<li>一开始,排列 <code>P=[1,2,3,...,m]</code>。</li>
13-
<li>对于当前的 <code>i</code> ,请你找出待查项 <code>queries[i]</code> 在排列 <code>P</code> 中的位置(<strong>下标从 0 开始</strong>),然后将其从原位置移动到排列 <code>P</code> 的起始位置(即下标为 0 处)。注意, <code>queries[i]</code><code>P</code> 中的位置就是 <code>queries[i]</code> 的查询结果。</li>
12+
<li>首先,你有一个排列&nbsp;<code>P=[1,2,3,...,m]</code>。</li>
13+
<li>对于当前的 <code>i</code> ,找到&nbsp;<code>queries[i]</code> 在排列 <code>P</code> 中的位置(<b>从 0 开始索引</b>),然后将它移到排列&nbsp;<code>P</code> 的开头(即下标为 0 处)。注意, <code>queries[i]</code>&nbsp;的查询结果是 <code>queries[i]</code> <code>P</code> 中移动前的位置。</li>
1414
</ul>
1515

16-
<p>请你以数组形式返回待查数组&nbsp; <code>queries</code> 的查询结果。</p>
16+
<p>返回一个数组,包含从给定 &nbsp;<code>queries</code>&nbsp;中查询到的结果。</p>
1717

1818
<p>&nbsp;</p>
1919

2020
<p><strong>示例 1:</strong></p>
2121

22-
<pre><strong>输入:</strong>queries = [3,1,2,1], m = 5
22+
<pre>
23+
<strong>输入:</strong>queries = [3,1,2,1], m = 5
2324
<strong>输出:</strong>[2,1,2,1]
24-
<strong>解释:</strong>待查数组 queries 处理如下
25-
对于 i=0: queries[i]=3, P=[1,2,3,4,5], 3 在 P 中的位置是 <strong>2</strong>,接着我们把 3 移动到 P 的起始位置,得到 P=[3,1,2,4,5] 。
26-
对于 i=1: queries[i]=1, P=[3,1,2,4,5], 1 在 P 中的位置是 <strong>1</strong>,接着我们把 1 移动到 P 的起始位置,得到 P=[1,3,2,4,5] 。
27-
对于 i=2: queries[i]=2, P=[1,3,2,4,5], 2 在 P 中的位置是 <strong>2</strong>,接着我们把 2 移动到 P 的起始位置,得到 P=[2,1,3,4,5] 。
28-
对于 i=3: queries[i]=1, P=[2,1,3,4,5], 1 在 P 中的位置是 <strong>1</strong>,接着我们把 1 移动到 P 的起始位置,得到 P=[1,2,3,4,5] 。
29-
因此,返回的结果数组为 [2,1,2,1] 。
25+
<strong>解释:处理</strong> queries 的过程如下
26+
对于 i=0: queries[i]=3, P=[1,2,3,4,5], 3 在 P 中的位置是 <strong>2</strong>,然后我们把 3 移动到 P 的开头,得到 P=[3,1,2,4,5] 。
27+
对于 i=1: queries[i]=1, P=[3,1,2,4,5], 1 在 P 中的位置是 <strong>1</strong>,然后我们把 1 移动到 P 的开头,得到 P=[1,3,2,4,5] 。
28+
对于 i=2: queries[i]=2, P=[1,3,2,4,5], 2 在 P 中的位置是 <strong>2</strong>,然后我们把 2 移动到 P 的开头,得到 P=[2,1,3,4,5] 。
29+
对于 i=3: queries[i]=1, P=[2,1,3,4,5], 1 在 P 中的位置是 <strong>1</strong>,然后我们把 1 移动到 P 的开头,得到 P=[1,2,3,4,5] 。
30+
因此,包含结果的数组为 [2,1,2,1] 。
3031
</pre>
3132

3233
<p><strong>示例 2:</strong></p>
3334

34-
<pre><strong>输入:</strong>queries = [4,1,2,2], m = 4
35+
<pre>
36+
<strong>输入:</strong>queries = [4,1,2,2], m = 4
3537
<strong>输出:</strong>[3,1,2,0]
3638
</pre>
3739

3840
<p><strong>示例 3:</strong></p>
3941

40-
<pre><strong>输入:</strong>queries = [7,5,5,8,3], m = 8
42+
<pre>
43+
<strong>输入:</strong>queries = [7,5,5,8,3], m = 8
4144
<strong>输出:</strong>[6,5,0,7,5]
4245
</pre>
4346

solution/1400-1499/1409.Queries on a Permutation With Key/README_EN.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
<ul>
1010
<li>In the beginning, you have the permutation <code>P=[1,2,3,...,m]</code>.</li>
11-
<li>For the current <code>i</code>, find the position of <code>queries[i]</code> in the permutation <code>P</code> (<strong>indexing from 0</strong>) and then move this at the beginning of the permutation <code>P.</code>&nbsp;Notice that the position of <code>queries[i]</code> in <code>P</code> is the result for <code>queries[i]</code>.</li>
11+
<li>For the current <code>i</code>, find the position of <code>queries[i]</code> in the permutation <code>P</code> (<strong>indexing from 0</strong>) and then move this at the beginning of the permutation <code>P</code>. Notice that the position of <code>queries[i]</code> in <code>P</code> is the result for <code>queries[i]</code>.</li>
1212
</ul>
1313

1414
<p>Return an array containing the result for the given <code>queries</code>.</p>

solution/1400-1499/1420.Build Array Where You Can Find The Maximum Exactly K Comparisons/README.md

+13-23
Original file line numberDiff line numberDiff line change
@@ -6,54 +6,44 @@
66

77
<!-- 这里写题目描述 -->
88

9-
<p>给你三个整数 <code>n</code>、<code>m</code> 和 <code>k</code> 。下图描述的算法用于找出正整数数组中最大的元素。</p>
9+
<p>给定三个整数 <code>n</code>、<code>m</code> 和 <code>k</code> 。考虑使用下图描述的算法找出正整数数组中最大的元素。</p>
1010

11-
<p><img alt="" src="https://fastly.jsdelivr.net/gh/doocs/leetcode@main/solution/1400-1499/1420.Build%20Array%20Where%20You%20Can%20Find%20The%20Maximum%20Exactly%20K%20Comparisons/images/e.png" style="height: 372px; width: 424px;"></p>
11+
<p><img alt="" src="https://fastly.jsdelivr.net/gh/doocs/leetcode@main/solution/1400-1499/1420.Build%20Array%20Where%20You%20Can%20Find%20The%20Maximum%20Exactly%20K%20Comparisons/images/e.png" style="height: 372px; width: 424px;" /></p>
1212

13-
<p>请你生成一个具有下述属性的数组 <code>arr</code> :</p>
13+
<p>请你构建一个具有以下属性的数组 <code>arr</code> :</p>
1414

1515
<ul>
16-
<li><code>arr</code> 中有 <code>n</code> 个整数。</li>
16+
<li><code>arr</code> 中包含确切的&nbsp;<code>n</code> 个整数。</li>
1717
<li><code>1 &lt;= arr[i] &lt;= m</code> 其中 <code>(0 &lt;= i &lt; n)</code> 。</li>
18-
<li>将上面提到的算法应用于 <code>arr</code> ,<code>search_cost</code> 的值等于 <code>k</code> 。</li>
18+
<li>将上面提到的算法应用于 <code>arr</code>&nbsp;之后,<code>search_cost</code> 的值等于 <code>k</code> 。</li>
1919
</ul>
2020

21-
<p>返回上述条件下生成数组 <code>arr</code> 的 <strong>方法数</strong> ,由于答案可能会很大,所以 <strong>必须</strong> 对 <code>10^9 + 7</code> 取余。</p>
21+
<p>返回在满足上述条件的情况下构建数组 <code>arr</code> 的 <em>方法数量</em>&nbsp;,由于答案可能会很大,所以 <strong>必须</strong> 对 <code>10^9 + 7</code> 取余。</p>
2222

2323
<p>&nbsp;</p>
2424

2525
<p><strong>示例 1:</strong></p>
2626

27-
<pre><strong>输入:</strong>n = 2, m = 3, k = 1
27+
<pre>
28+
<strong>输入:</strong>n = 2, m = 3, k = 1
2829
<strong>输出:</strong>6
2930
<strong>解释:</strong>可能的数组分别为 [1, 1], [2, 1], [2, 2], [3, 1], [3, 2] [3, 3]
3031
</pre>
3132

3233
<p><strong>示例 2:</strong></p>
3334

34-
<pre><strong>输入:</strong>n = 5, m = 2, k = 3
35+
<pre>
36+
<strong>输入:</strong>n = 5, m = 2, k = 3
3537
<strong>输出:</strong>0
3638
<strong>解释:</strong>没有数组可以满足上述条件
3739
</pre>
3840

3941
<p><strong>示例 3:</strong></p>
4042

41-
<pre><strong>输入:</strong>n = 9, m = 1, k = 1
43+
<pre>
44+
<strong>输入:</strong>n = 9, m = 1, k = 1
4245
<strong>输出:</strong>1
43-
<strong>解释:</strong>可能的数组只有 [1, 1, 1, 1, 1, 1, 1, 1, 1]
44-
</pre>
45-
46-
<p><strong>示例 4:</strong></p>
47-
48-
<pre><strong>输入:</strong>n = 50, m = 100, k = 25
49-
<strong>输出:</strong>34549172
50-
<strong>解释:</strong>不要忘了对 1000000007 取余
51-
</pre>
52-
53-
<p><strong>示例 5:</strong></p>
54-
55-
<pre><strong>输入:</strong>n = 37, m = 17, k = 7
56-
<strong>输出:</strong>418930126
46+
<strong>解释:</strong>唯一可能的数组是 [1, 1, 1, 1, 1, 1, 1, 1, 1]
5747
</pre>
5848

5949
<p>&nbsp;</p>

solution/1400-1499/1420.Build Array Where You Can Find The Maximum Exactly K Comparisons/README_EN.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
<pre>
3131
<strong>Input:</strong> n = 5, m = 2, k = 3
3232
<strong>Output:</strong> 0
33-
<strong>Explanation:</strong> There are no possible arrays that satisify the mentioned conditions.
33+
<strong>Explanation:</strong> There are no possible arrays that satisfy the mentioned conditions.
3434
</pre>
3535

3636
<p><strong class="example">Example 3:</strong></p>

solution/2200-2299/2251.Number of Flowers in Full Bloom/README_EN.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
<p><strong class="example">Example 1:</strong></p>
1313
<img alt="" src="https://fastly.jsdelivr.net/gh/doocs/leetcode@main/solution/2200-2299/2251.Number%20of%20Flowers%20in%20Full%20Bloom/images/ex1new.jpg" style="width: 550px; height: 216px;" />
1414
<pre>
15-
<strong>Input:</strong> flowers = [[1,6],[3,7],[9,12],[4,13]], poeple = [2,3,7,11]
15+
<strong>Input:</strong> flowers = [[1,6],[3,7],[9,12],[4,13]], people = [2,3,7,11]
1616
<strong>Output:</strong> [1,2,2,2]
1717
<strong>Explanation: </strong>The figure above shows the times when the flowers are in full bloom and when the people arrive.
1818
For each person, we return the number of flowers in full bloom during their arrival.
@@ -21,7 +21,7 @@ For each person, we return the number of flowers in full bloom during their arri
2121
<p><strong class="example">Example 2:</strong></p>
2222
<img alt="" src="https://fastly.jsdelivr.net/gh/doocs/leetcode@main/solution/2200-2299/2251.Number%20of%20Flowers%20in%20Full%20Bloom/images/ex2new.jpg" style="width: 450px; height: 195px;" />
2323
<pre>
24-
<strong>Input:</strong> flowers = [[1,10],[3,3]], poeple = [3,3,2]
24+
<strong>Input:</strong> flowers = [[1,10],[3,3]], people = [3,3,2]
2525
<strong>Output:</strong> [2,2,1]
2626
<strong>Explanation:</strong> The figure above shows the times when the flowers are in full bloom and when the people arrive.
2727
For each person, we return the number of flowers in full bloom during their arrival.

solution/2600-2699/2668.Find Latest Salaries/README.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
| salary | varchar |
1919
| department_id | varchar |
2020
+---------------+---------+
21-
在 SQL 中,(emp_id, salary) 是此表的主键。
21+
(emp_id, salary) 是该表的主键(具有唯一值的列的组合)。
2222
每行包含员工的详细信息和他们每年的薪水,但有些记录是旧的,包含过时的薪资信息。
2323
</pre>
2424

@@ -41,7 +41,7 @@
4141
| 1 | Todd | Wilson | 110000 | D1006 |
4242
| 1 | Todd | Wilson | 106119 | D1006 |
4343
| 2 | Justin | Simon | 128922 | D1005 |
44-
| 2 | Justin | Simon | 128922 | D1005 |
44+
| 2 | Justin | Simon | 130000 | D1005 |
4545
| 3 | Kelly | Rosario | 42689 | D1002 |
4646
| 4 | Patricia | Powell | 162825 | D1004 |
4747
| 4 | Patricia | Powell | 170000 | D1004 |

solution/2600-2699/2668.Find Latest Salaries/README_EN.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ Each row contains employees details and their yearly salaries, however, some of
3838
| 1 | Todd | Wilson | 110000 | D1006 |
3939
| 1 | Todd | Wilson | 106119 | D1006 |
4040
| 2 | Justin | Simon | 128922 | D1005 |
41-
| 2 | Justin | Simon | 128922 | D1005 |
41+
| 2 | Justin | Simon | 130000 | D1005 |
4242
| 3 | Kelly | Rosario | 42689 | D1002 |
4343
| 4 | Patricia | Powell | 162825 | D1004 |
4444
| 4 | Patricia | Powell | 170000 | D1004 |

solution/2800-2899/2893.Calculate Orders Within Each Interval/README.md

+16-16
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
1-
# [2893. Calculate Orders Within Each Interval](https://leetcode.cn/problems/calculate-orders-within-each-interval)
1+
# [2893. 计算每个区间内的订单](https://leetcode.cn/problems/calculate-orders-within-each-interval)
22

33
[English Version](/solution/2800-2899/2893.Calculate%20Orders%20Within%20Each%20Interval/README_EN.md)
44

55
## 题目描述
66

77
<!-- 这里写题目描述 -->
88

9-
<p>Table: <code><font face="monospace">Orders</font></code></p>
9+
<p>表:&nbsp;<code><font face="monospace">Orders</font></code></p>
1010

1111
<pre>
1212
+-------------+------+
@@ -15,25 +15,25 @@
1515
| minute | int |
1616
| order_count | int |
1717
+-------------+------+
18-
minute is the primary key for this table.
19-
Each row of this table contains the minute and number of orders received during that specific minute. The total number of rows will be a multiple of 6.
20-
</pre>
18+
minute 是该表的主键。
19+
该表的每一行包含分钟数以及在特定分钟数内收到的订单数量。总行数将是 6 的倍数。</pre>
2120

22-
<p>Write a query to calculate <strong>total</strong> <strong>orders</strong><b> </b>within each <strong>interval</strong>. Each interval is defined as a combination of <code>6</code> minutes.</p>
21+
<p>编写一个查询,计算每个&nbsp;<strong>区间</strong><b>&nbsp;</b>内的&nbsp;<b>总订单数量。</b>&nbsp;每个区间被定义为&nbsp;<code>6</code>&nbsp;分钟的组合。</p>
2322

2423
<ul>
25-
<li>Minutes <code>1</code> to <code>6</code> fall within interval <code>1</code>, while minutes <code>7</code> to <code>12</code> belong to interval <code>2</code>, and so forth.</li>
24+
<li>&nbsp;<code>1</code>&nbsp;到&nbsp;<code>6</code>&nbsp;分钟属于第&nbsp;<code>1</code>&nbsp;个区间,而&nbsp;<code>7</code>&nbsp;到&nbsp;<code>12</code>&nbsp;分钟属于第&nbsp;<code>2</code>&nbsp;个区间,以此类推。</li>
2625
</ul>
2726

28-
<p>Return<em> the result table ordered by <strong>interval_no</strong> in <strong>ascending</strong> order.</em></p>
27+
<p><em><strong>升序顺序</strong></em> <em>返回</em><em>结果表,</em>按<em>&nbsp;<strong>interval_no</strong>&nbsp;排序。</em></p>
2928

30-
<p>The result format is in the following example.</p>
29+
<p>结果表的格式如下示例所示。</p>
3130

3231
<p>&nbsp;</p>
33-
<p><strong class="example">Example 1:</strong></p>
32+
33+
<p><b>示例 1:</b></p>
3434

3535
<pre>
36-
<strong>Input:</strong>
36+
<b>输入:</b>
3737
Orders table:
3838
+--------+-------------+
3939
| minute | order_count |
@@ -51,17 +51,17 @@ Orders table:
5151
| 11 | 4 |
5252
| 12 | 6 |
5353
+--------+-------------+
54-
<strong>Output:</strong>
54+
<b>输出:</b>
5555
+-------------+--------------+
5656
| interval_no | total_orders |
5757
+-------------+--------------+
5858
| 1 | 17 |
5959
| 2 | 18 |
6060
+-------------+--------------+
61-
<strong>Explanation:</strong>
62-
- Interval number 1 comprises minutes from 1 to 6. The total orders in these six minutes are (0 + 2 + 4 + 6 + 1 + 4) = 17.
63-
- Interval number 2 comprises minutes from 7 to 12. The total orders in these six minutes are (1 + 2 + 4 + 1 + 4 + 6) = 18.
64-
Returning table orderd by interval_no in ascending order.</pre>
61+
<b>解释:</b>
62+
- 区间号 1 包括从 1 到 6 分钟的时间。这 6 分钟内的总订单数量为 (0 + 2 + 4 + 6 + 1 + 4) = 17
63+
- 区间号 2 包括从 7 到 12 分钟的时间。这 6 分钟内的总订单数量为 (1 + 2 + 4 + 1 + 4 + 6) = 18
64+
按升序顺序返回结果表,按 interval_no 排序。</pre>
6565

6666
## 解法
6767

solution/DATABASE_README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -245,7 +245,7 @@
245245
| 2837 | [总旅行距离](/solution/2800-2899/2837.Total%20Traveled%20Distance/README.md) | `数据库` | 简单 | 🔒 |
246246
| 2853 | [最高薪水差异](/solution/2800-2899/2853.Highest%20Salaries%20Difference/README.md) | `数据库` | 简单 | 🔒 |
247247
| 2854 | [滚动平均步数](/solution/2800-2899/2854.Rolling%20Average%20Steps/README.md) | `数据库` | 中等 | 🔒 |
248-
| 2893 | [Calculate Orders Within Each Interval](/solution/2800-2899/2893.Calculate%20Orders%20Within%20Each%20Interval/README.md) | | 中等 | 🔒 |
248+
| 2893 | [计算每个区间内的订单](/solution/2800-2899/2893.Calculate%20Orders%20Within%20Each%20Interval/README.md) | `数据库` | 中等 | 🔒 |
249249

250250
## 版权
251251

0 commit comments

Comments
 (0)