Skip to content

Commit 76e8b50

Browse files
authored
feat: update lc problems (doocs#3556)
1 parent cf2a9dd commit 76e8b50

File tree

21 files changed

+231
-17
lines changed

21 files changed

+231
-17
lines changed

solution/1200-1299/1246.Palindrome Removal/README.md

+29
Original file line numberDiff line numberDiff line change
@@ -181,6 +181,35 @@ func minimumMoves(arr []int) int {
181181
}
182182
```
183183

184+
#### TypeScript
185+
186+
```ts
187+
function minimumMoves(arr: number[]): number {
188+
const n = arr.length;
189+
const f: number[][] = Array.from({ length: n }, () => Array(n).fill(0));
190+
191+
for (let i = 0; i < n; ++i) {
192+
f[i][i] = 1;
193+
}
194+
195+
for (let i = n - 2; i >= 0; --i) {
196+
for (let j = i + 1; j < n; ++j) {
197+
if (i + 1 === j) {
198+
f[i][j] = arr[i] === arr[j] ? 1 : 2;
199+
} else {
200+
let t = arr[i] === arr[j] ? f[i + 1][j - 1] : Infinity;
201+
for (let k = i; k < j; ++k) {
202+
t = Math.min(t, f[i][k] + f[k + 1][j]);
203+
}
204+
f[i][j] = t;
205+
}
206+
}
207+
}
208+
209+
return f[0][n - 1];
210+
}
211+
```
212+
184213
<!-- tabs:end -->
185214

186215
<!-- solution:end -->

solution/1200-1299/1246.Palindrome Removal/README_EN.md

+29
Original file line numberDiff line numberDiff line change
@@ -181,6 +181,35 @@ func minimumMoves(arr []int) int {
181181
}
182182
```
183183

184+
#### TypeScript
185+
186+
```ts
187+
function minimumMoves(arr: number[]): number {
188+
const n = arr.length;
189+
const f: number[][] = Array.from({ length: n }, () => Array(n).fill(0));
190+
191+
for (let i = 0; i < n; ++i) {
192+
f[i][i] = 1;
193+
}
194+
195+
for (let i = n - 2; i >= 0; --i) {
196+
for (let j = i + 1; j < n; ++j) {
197+
if (i + 1 === j) {
198+
f[i][j] = arr[i] === arr[j] ? 1 : 2;
199+
} else {
200+
let t = arr[i] === arr[j] ? f[i + 1][j - 1] : Infinity;
201+
for (let k = i; k < j; ++k) {
202+
t = Math.min(t, f[i][k] + f[k + 1][j]);
203+
}
204+
f[i][j] = t;
205+
}
206+
}
207+
}
208+
209+
return f[0][n - 1];
210+
}
211+
```
212+
184213
<!-- tabs:end -->
185214

186215
<!-- solution:end -->
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
function minimumMoves(arr: number[]): number {
2+
const n = arr.length;
3+
const f: number[][] = Array.from({ length: n }, () => Array(n).fill(0));
4+
5+
for (let i = 0; i < n; ++i) {
6+
f[i][i] = 1;
7+
}
8+
9+
for (let i = n - 2; i >= 0; --i) {
10+
for (let j = i + 1; j < n; ++j) {
11+
if (i + 1 === j) {
12+
f[i][j] = arr[i] === arr[j] ? 1 : 2;
13+
} else {
14+
let t = arr[i] === arr[j] ? f[i + 1][j - 1] : Infinity;
15+
for (let k = i; k < j; ++k) {
16+
t = Math.min(t, f[i][k] + f[k + 1][j]);
17+
}
18+
f[i][j] = t;
19+
}
20+
}
21+
}
22+
23+
return f[0][n - 1];
24+
}

solution/1200-1299/1247.Minimum Swaps to Make Strings Equal/README.md

+25-3
Original file line numberDiff line numberDiff line change
@@ -73,13 +73,13 @@ tags:
7373

7474
### 方法一:贪心
7575

76-
根据题目描述,两个字符串 $s1$ 和 $s2$ 都只包含字符 $x$ 和 $y$,且长度相同,因此可以将 $s1$ 和 $s2$ 中的字符一一对应起来,即 $s1[i]$ 和 $s2[i]$。
76+
根据题目描述,两个字符串 $s_1$ 和 $s_2$ 都只包含字符 $x$ 和 $y$,且长度相同,因此可以将 $s_1$ 和 $s_2$ 中的字符一一对应起来,即 $s_1[i]$ 和 $s_2[i]$。
7777

78-
如果 $s1[i] = s2[i]$,则不需要交换,直接跳过即可。如果 $s1[i] \neq s2[i]$,则需要交换,我们统计 $s1[i]$ 和 $s2[i]$ 的组合情况,即 $s1[i] = x$ 且 $s2[i] = y$ 的情况,记为 $xy$,对于 $s1[i] = y$ 且 $s2[i] = x$ 的情况,记为 $yx$。
78+
如果 $s_1[i] = s_2[i]$,则不需要交换,直接跳过即可。如果 $s_1[i] \neq s_2[i]$,则需要交换,我们统计 $s_1[i]$ 和 $s_2[i]$ 的组合情况,即 $s_1[i] = x$ 且 $s_2[i] = y$ 的情况,记为 $xy$,对于 $s_1[i] = y$ 且 $s_2[i] = x$ 的情况,记为 $yx$。
7979

8080
如果 $xy + yx$ 为奇数,则无法完成交换,返回 $-1$。如果 $xy + yx$ 为偶数,则需要交换的次数为 $\left \lfloor \frac{x}{2} \right \rfloor$ + $\left \lfloor \frac{y}{2} \right \rfloor$ + $xy \bmod{2}$ + $yx \bmod{2}$。
8181

82-
时间复杂度 $O(n)$,其中 $n$ 为字符串 $s1$ 和 $s2$ 的长度。空间复杂度 $O(1)$。
82+
时间复杂度 $O(n)$,其中 $n$ 为字符串 $s_1$ 和 $s_2$ 的长度。空间复杂度 $O(1)$。
8383

8484
<!-- tabs:start -->
8585

@@ -160,6 +160,28 @@ func minimumSwap(s1 string, s2 string) int {
160160
}
161161
```
162162

163+
#### TypeScript
164+
165+
```ts
166+
function minimumSwap(s1: string, s2: string): number {
167+
let xy = 0,
168+
yx = 0;
169+
170+
for (let i = 0; i < s1.length; ++i) {
171+
const a = s1[i],
172+
b = s2[i];
173+
xy += a < b ? 1 : 0;
174+
yx += a > b ? 1 : 0;
175+
}
176+
177+
if ((xy + yx) % 2 !== 0) {
178+
return -1;
179+
}
180+
181+
return Math.floor(xy / 2) + Math.floor(yx / 2) + (xy % 2) + (yx % 2);
182+
}
183+
```
184+
163185
#### JavaScript
164186

165187
```js

solution/1200-1299/1247.Minimum Swaps to Make Strings Equal/README_EN.md

+26-4
Original file line numberDiff line numberDiff line change
@@ -67,13 +67,13 @@ Note that you cannot swap s1[0] and s1[1] to make s1 equal to &quot;yx&quot;, ca
6767

6868
### Solution 1: Greedy
6969

70-
According to the problem description, both strings $s1$ and $s2$ only contain characters $x$ and $y$, and have the same length. Therefore, we can pair the characters in $s1$ and $s2$, i.e., $s1[i]$ and $s2[i]$.
70+
According to the problem description, both strings $s_1$ and $s_2$ contain only the characters $x$ and $y$, and they have the same length. Therefore, we can match the characters in $s_1$ and $s_2$ one by one, i.e., $s_1[i]$ and $s_2[i]$.
7171

72-
If $s1[i] = s2[i]$, no swap is needed, and we can skip it. If $s1[i] \neq s2[i]$, a swap is needed. We count the combination of $s1[i]$ and $s2[i]$, i.e., the situation where $s1[i] = x$ and $s2[i] = y$, denoted as $xy$, and the situation where $s1[i] = y$ and $s2[i] = x$, denoted as $yx$.
72+
If $s_1[i] = s_2[i]$, no swap is needed, and we can skip to the next character. If $s_1[i] \neq s_2[i]$, a swap is needed. We count the combinations of $s_1[i]$ and $s_2[i]$: if $s_1[i] = x$ and $s_2[i] = y$, we denote it as $xy$; if $s_1[i] = y$ and $s_2[i] = x$, we denote it as $yx$.
7373

74-
If $xy + yx$ is odd, the swap cannot be completed, and we return $-1$. If $xy + yx$ is even, the number of swaps needed is $\left \lfloor \frac{x}{2} \right \rfloor$ + $\left \lfloor \frac{y}{2} \right \rfloor$ + $xy \bmod{2}$ + $yx \bmod{2}$.
74+
If $xy + yx$ is odd, it is impossible to complete the swaps, and we return $-1$. If $xy + yx$ is even, the number of swaps needed is $\left \lfloor \frac{xy}{2} \right \rfloor + \left \lfloor \frac{yx}{2} \right \rfloor + xy \bmod{2} + yx \bmod{2}$.
7575

76-
The time complexity is $O(n)$, where $n$ is the length of the strings $s1$ and $s2$. The space complexity is $O(1)$.
76+
The time complexity is $O(n)$, where $n$ is the length of the strings $s_1$ and $s_2$. The space complexity is $O(1)$.
7777

7878
<!-- tabs:start -->
7979

@@ -154,6 +154,28 @@ func minimumSwap(s1 string, s2 string) int {
154154
}
155155
```
156156

157+
#### TypeScript
158+
159+
```ts
160+
function minimumSwap(s1: string, s2: string): number {
161+
let xy = 0,
162+
yx = 0;
163+
164+
for (let i = 0; i < s1.length; ++i) {
165+
const a = s1[i],
166+
b = s2[i];
167+
xy += a < b ? 1 : 0;
168+
yx += a > b ? 1 : 0;
169+
}
170+
171+
if ((xy + yx) % 2 !== 0) {
172+
return -1;
173+
}
174+
175+
return Math.floor(xy / 2) + Math.floor(yx / 2) + (xy % 2) + (yx % 2);
176+
}
177+
```
178+
157179
#### JavaScript
158180

159181
```js
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
function minimumSwap(s1: string, s2: string): number {
2+
let xy = 0,
3+
yx = 0;
4+
5+
for (let i = 0; i < s1.length; ++i) {
6+
const a = s1[i],
7+
b = s2[i];
8+
xy += a < b ? 1 : 0;
9+
yx += a > b ? 1 : 0;
10+
}
11+
12+
if ((xy + yx) % 2 !== 0) {
13+
return -1;
14+
}
15+
16+
return Math.floor(xy / 2) + Math.floor(yx / 2) + (xy % 2) + (yx % 2);
17+
}

solution/1200-1299/1250.Check If It Is a Good Array/README.md

+12
Original file line numberDiff line numberDiff line change
@@ -137,6 +137,18 @@ func gcd(a, b int) int {
137137
}
138138
```
139139

140+
#### TypeScript
141+
142+
```ts
143+
function isGoodArray(nums: number[]): boolean {
144+
return nums.reduce(gcd) === 1;
145+
}
146+
147+
function gcd(a: number, b: number): number {
148+
return b === 0 ? a : gcd(b, a % b);
149+
}
150+
```
151+
140152
<!-- tabs:end -->
141153

142154
<!-- solution:end -->

solution/1200-1299/1250.Check If It Is a Good Array/README_EN.md

+12
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,18 @@ func gcd(a, b int) int {
138138
}
139139
```
140140

141+
#### TypeScript
142+
143+
```ts
144+
function isGoodArray(nums: number[]): boolean {
145+
return nums.reduce(gcd) === 1;
146+
}
147+
148+
function gcd(a: number, b: number): number {
149+
return b === 0 ? a : gcd(b, a % b);
150+
}
151+
```
152+
141153
<!-- tabs:end -->
142154

143155
<!-- solution:end -->
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
function isGoodArray(nums: number[]): boolean {
2+
return nums.reduce(gcd) === 1;
3+
}
4+
5+
function gcd(a: number, b: number): number {
6+
return b === 0 ? a : gcd(b, a % b);
7+
}

solution/3200-3299/3294.Convert Doubly Linked List to Array II/README.md

+4
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22
comments: true
33
difficulty: 中等
44
edit_url: https://github.com/doocs/leetcode/edit/main/solution/3200-3299/3294.Convert%20Doubly%20Linked%20List%20to%20Array%20II/README.md
5+
tags:
6+
- 数组
7+
- 链表
8+
- 双向链表
59
---
610

711
<!-- problem:start -->

solution/3200-3299/3294.Convert Doubly Linked List to Array II/README_EN.md

+4
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22
comments: true
33
difficulty: Medium
44
edit_url: https://github.com/doocs/leetcode/edit/main/solution/3200-3299/3294.Convert%20Doubly%20Linked%20List%20to%20Array%20II/README_EN.md
5+
tags:
6+
- Array
7+
- Linked List
8+
- Doubly-Linked List
59
---
610

711
<!-- problem:start -->

solution/3200-3299/3295.Report Spam Message/README.md

+4
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22
comments: true
33
difficulty: 中等
44
edit_url: https://github.com/doocs/leetcode/edit/main/solution/3200-3299/3295.Report%20Spam%20Message/README.md
5+
tags:
6+
- 数组
7+
- 哈希表
8+
- 字符串
59
---
610

711
<!-- problem:start -->

solution/3200-3299/3295.Report Spam Message/README_EN.md

+4
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22
comments: true
33
difficulty: Medium
44
edit_url: https://github.com/doocs/leetcode/edit/main/solution/3200-3299/3295.Report%20Spam%20Message/README_EN.md
5+
tags:
6+
- Array
7+
- Hash Table
8+
- String
59
---
610

711
<!-- problem:start -->

solution/3200-3299/3296.Minimum Number of Seconds to Make Mountain Height Zero/README.md

+4
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22
comments: true
33
difficulty: 中等
44
edit_url: https://github.com/doocs/leetcode/edit/main/solution/3200-3299/3296.Minimum%20Number%20of%20Seconds%20to%20Make%20Mountain%20Height%20Zero/README.md
5+
tags:
6+
- 数组
7+
- 数学
8+
- 二分查找
59
---
610

711
<!-- problem:start -->

solution/3200-3299/3296.Minimum Number of Seconds to Make Mountain Height Zero/README_EN.md

+4
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22
comments: true
33
difficulty: Medium
44
edit_url: https://github.com/doocs/leetcode/edit/main/solution/3200-3299/3296.Minimum%20Number%20of%20Seconds%20to%20Make%20Mountain%20Height%20Zero/README_EN.md
5+
tags:
6+
- Array
7+
- Math
8+
- Binary Search
59
---
610

711
<!-- problem:start -->

solution/3200-3299/3297.Count Substrings That Can Be Rearranged to Contain a String I/README.md

+4
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22
comments: true
33
difficulty: 中等
44
edit_url: https://github.com/doocs/leetcode/edit/main/solution/3200-3299/3297.Count%20Substrings%20That%20Can%20Be%20Rearranged%20to%20Contain%20a%20String%20I/README.md
5+
tags:
6+
- 哈希表
7+
- 字符串
8+
- 滑动窗口
59
---
610

711
<!-- problem:start -->

solution/3200-3299/3297.Count Substrings That Can Be Rearranged to Contain a String I/README_EN.md

+4
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22
comments: true
33
difficulty: Medium
44
edit_url: https://github.com/doocs/leetcode/edit/main/solution/3200-3299/3297.Count%20Substrings%20That%20Can%20Be%20Rearranged%20to%20Contain%20a%20String%20I/README_EN.md
5+
tags:
6+
- Hash Table
7+
- String
8+
- Sliding Window
59
---
610

711
<!-- problem:start -->

solution/3200-3299/3298.Count Substrings That Can Be Rearranged to Contain a String II/README.md

+4
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22
comments: true
33
difficulty: 困难
44
edit_url: https://github.com/doocs/leetcode/edit/main/solution/3200-3299/3298.Count%20Substrings%20That%20Can%20Be%20Rearranged%20to%20Contain%20a%20String%20II/README.md
5+
tags:
6+
- 哈希表
7+
- 字符串
8+
- 滑动窗口
59
---
610

711
<!-- problem:start -->

solution/3200-3299/3298.Count Substrings That Can Be Rearranged to Contain a String II/README_EN.md

+4
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22
comments: true
33
difficulty: Hard
44
edit_url: https://github.com/doocs/leetcode/edit/main/solution/3200-3299/3298.Count%20Substrings%20That%20Can%20Be%20Rearranged%20to%20Contain%20a%20String%20II/README_EN.md
5+
tags:
6+
- Hash Table
7+
- String
8+
- Sliding Window
59
---
610

711
<!-- problem:start -->

solution/README.md

+5-5
Original file line numberDiff line numberDiff line change
@@ -3304,11 +3304,11 @@
33043304
| 3291 | [形成目标字符串需要的最少字符串数 I](/solution/3200-3299/3291.Minimum%20Number%20of%20Valid%20Strings%20to%20Form%20Target%20I/README.md) | `字典树`,`线段树`,`数组`,`字符串`,`二分查找`,`动态规划`,`字符串匹配`,`哈希函数`,`滚动哈希` | 中等 | 第 415 场周赛 |
33053305
| 3292 | [形成目标字符串需要的最少字符串数 II](/solution/3200-3299/3292.Minimum%20Number%20of%20Valid%20Strings%20to%20Form%20Target%20II/README.md) | `线段树`,`数组`,`字符串`,`二分查找`,`动态规划`,`字符串匹配`,`哈希函数`,`滚动哈希` | 困难 | 第 415 场周赛 |
33063306
| 3293 | [计算产品最终价格](/solution/3200-3299/3293.Calculate%20Product%20Final%20Price/README.md) | `数据库` | 中等 | 🔒 |
3307-
| 3294 | [将双链表转换为数组 II](/solution/3200-3299/3294.Convert%20Doubly%20Linked%20List%20to%20Array%20II/README.md) | | 中等 | 🔒 |
3308-
| 3295 | [举报垃圾信息](/solution/3200-3299/3295.Report%20Spam%20Message/README.md) | | 中等 | 第 416 场周赛 |
3309-
| 3296 | [移山所需的最少秒数](/solution/3200-3299/3296.Minimum%20Number%20of%20Seconds%20to%20Make%20Mountain%20Height%20Zero/README.md) | | 中等 | 第 416 场周赛 |
3310-
| 3297 | [统计重新排列后包含另一个字符串的子字符串数目 I](/solution/3200-3299/3297.Count%20Substrings%20That%20Can%20Be%20Rearranged%20to%20Contain%20a%20String%20I/README.md) | | 中等 | 第 416 场周赛 |
3311-
| 3298 | [统计重新排列后包含另一个字符串的子字符串数目 II](/solution/3200-3299/3298.Count%20Substrings%20That%20Can%20Be%20Rearranged%20to%20Contain%20a%20String%20II/README.md) | | 困难 | 第 416 场周赛 |
3307+
| 3294 | [将双链表转换为数组 II](/solution/3200-3299/3294.Convert%20Doubly%20Linked%20List%20to%20Array%20II/README.md) | `数组`,`链表`,`双向链表` | 中等 | 🔒 |
3308+
| 3295 | [举报垃圾信息](/solution/3200-3299/3295.Report%20Spam%20Message/README.md) | `数组`,`哈希表`,`字符串` | 中等 | 第 416 场周赛 |
3309+
| 3296 | [移山所需的最少秒数](/solution/3200-3299/3296.Minimum%20Number%20of%20Seconds%20to%20Make%20Mountain%20Height%20Zero/README.md) | `数组`,`数学`,`二分查找` | 中等 | 第 416 场周赛 |
3310+
| 3297 | [统计重新排列后包含另一个字符串的子字符串数目 I](/solution/3200-3299/3297.Count%20Substrings%20That%20Can%20Be%20Rearranged%20to%20Contain%20a%20String%20I/README.md) | `哈希表`,`字符串`,`滑动窗口` | 中等 | 第 416 场周赛 |
3311+
| 3298 | [统计重新排列后包含另一个字符串的子字符串数目 II](/solution/3200-3299/3298.Count%20Substrings%20That%20Can%20Be%20Rearranged%20to%20Contain%20a%20String%20II/README.md) | `哈希表`,`字符串`,`滑动窗口` | 困难 | 第 416 场周赛 |
33123312

33133313
## 版权
33143314

solution/README_EN.md

+5-5
Original file line numberDiff line numberDiff line change
@@ -3302,11 +3302,11 @@ Press <kbd>Control</kbd> + <kbd>F</kbd>(or <kbd>Command</kbd> + <kbd>F</kbd> on
33023302
| 3291 | [Minimum Number of Valid Strings to Form Target I](/solution/3200-3299/3291.Minimum%20Number%20of%20Valid%20Strings%20to%20Form%20Target%20I/README_EN.md) | `Trie`,`Segment Tree`,`Array`,`String`,`Binary Search`,`Dynamic Programming`,`String Matching`,`Hash Function`,`Rolling Hash` | Medium | Weekly Contest 415 |
33033303
| 3292 | [Minimum Number of Valid Strings to Form Target II](/solution/3200-3299/3292.Minimum%20Number%20of%20Valid%20Strings%20to%20Form%20Target%20II/README_EN.md) | `Segment Tree`,`Array`,`String`,`Binary Search`,`Dynamic Programming`,`String Matching`,`Hash Function`,`Rolling Hash` | Hard | Weekly Contest 415 |
33043304
| 3293 | [Calculate Product Final Price](/solution/3200-3299/3293.Calculate%20Product%20Final%20Price/README_EN.md) | `Database` | Medium | 🔒 |
3305-
| 3294 | [Convert Doubly Linked List to Array II](/solution/3200-3299/3294.Convert%20Doubly%20Linked%20List%20to%20Array%20II/README_EN.md) | | Medium | 🔒 |
3306-
| 3295 | [Report Spam Message](/solution/3200-3299/3295.Report%20Spam%20Message/README_EN.md) | | Medium | Weekly Contest 416 |
3307-
| 3296 | [Minimum Number of Seconds to Make Mountain Height Zero](/solution/3200-3299/3296.Minimum%20Number%20of%20Seconds%20to%20Make%20Mountain%20Height%20Zero/README_EN.md) | | Medium | Weekly Contest 416 |
3308-
| 3297 | [Count Substrings That Can Be Rearranged to Contain a String I](/solution/3200-3299/3297.Count%20Substrings%20That%20Can%20Be%20Rearranged%20to%20Contain%20a%20String%20I/README_EN.md) | | Medium | Weekly Contest 416 |
3309-
| 3298 | [Count Substrings That Can Be Rearranged to Contain a String II](/solution/3200-3299/3298.Count%20Substrings%20That%20Can%20Be%20Rearranged%20to%20Contain%20a%20String%20II/README_EN.md) | | Hard | Weekly Contest 416 |
3305+
| 3294 | [Convert Doubly Linked List to Array II](/solution/3200-3299/3294.Convert%20Doubly%20Linked%20List%20to%20Array%20II/README_EN.md) | `Array`,`Linked List`,`Doubly-Linked List` | Medium | 🔒 |
3306+
| 3295 | [Report Spam Message](/solution/3200-3299/3295.Report%20Spam%20Message/README_EN.md) | `Array`,`Hash Table`,`String` | Medium | Weekly Contest 416 |
3307+
| 3296 | [Minimum Number of Seconds to Make Mountain Height Zero](/solution/3200-3299/3296.Minimum%20Number%20of%20Seconds%20to%20Make%20Mountain%20Height%20Zero/README_EN.md) | `Array`,`Math`,`Binary Search` | Medium | Weekly Contest 416 |
3308+
| 3297 | [Count Substrings That Can Be Rearranged to Contain a String I](/solution/3200-3299/3297.Count%20Substrings%20That%20Can%20Be%20Rearranged%20to%20Contain%20a%20String%20I/README_EN.md) | `Hash Table`,`String`,`Sliding Window` | Medium | Weekly Contest 416 |
3309+
| 3298 | [Count Substrings That Can Be Rearranged to Contain a String II](/solution/3200-3299/3298.Count%20Substrings%20That%20Can%20Be%20Rearranged%20to%20Contain%20a%20String%20II/README_EN.md) | `Hash Table`,`String`,`Sliding Window` | Hard | Weekly Contest 416 |
33103310

33113311
## Copyright
33123312

0 commit comments

Comments
 (0)