Skip to content

Commit 66e047b

Browse files
committed
update readme
1 parent 7290c29 commit 66e047b

File tree

7 files changed

+9
-91
lines changed

7 files changed

+9
-91
lines changed

.github/test.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2435-paths-in-matrix-whose-sum-is-divisible-by-k python hard
1+
3381-maximum-subarray-sum-with-length-divisible-by-k python medium

2872-maximum-number-of-k-divisible-components/2872-maximum-number-of-k-divisible-components.py

Lines changed: 0 additions & 39 deletions
This file was deleted.

2872-maximum-number-of-k-divisible-components/README.md

Lines changed: 0 additions & 45 deletions
This file was deleted.

Question_List_3001_4000.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -132,6 +132,7 @@
132132
| 3375 | [Minimum Operations to Make Array Values Equal to K](https://leetcode.com/problems/minimum-operations-to-make-array-values-equal-to-k) | [Python](./Python/3375-minimum-operations-to-make-array-values-equal-to-k.py) | [Easy](./Readme/3375-minimum-operations-to-make-array-values-equal-to-k.md) |
133133
| 3379 | [Transformed Array](https://leetcode.com/problems/transformed-array) | [Python](./Python/3379-transformed-array.py) | [Easy](./Readme/3379-transformed-array.md) |
134134
| 3380 | [Maximum Area Rectangle With Point Constraints I](https://leetcode.com/problems/maximum-area-rectangle-with-point-constraints-i) | [Python](./Python/3380-maximum-area-rectangle-with-point-constraints-i.py) | [Medium](./Readme/3380-maximum-area-rectangle-with-point-constraints-i.md) |
135+
| 3381 | [Maximum Subarray Sum with Length Divisible by K](https://leetcode.com/problems/maximum-subarray-sum-with-length-divisible-by-k) | [Python](./Python/3381-maximum-subarray-sum-with-length-divisible-by-k.py) | [Medium](./Readme/3381-maximum-subarray-sum-with-length-divisible-by-k.md) |
135136
| 3386 | [Button With Longest Push Time](https://leetcode.com/problems/button-with-longest-push-time) | [Python](./Python/3386-button-with-longest-push-time.py) | [Easy](./Readme/3386-button-with-longest-push-time.md) |
136137
| 3387 | [Maximize Amount After Two Days of Conversions](https://leetcode.com/problems/maximize-amount-after-two-days-of-conversions) | [Python](./Python/3387-maximize-amount-after-two-days-of-conversions.py) | [Medium](./Readme/3387-maximize-amount-after-two-days-of-conversions.md) |
137138
| 3392 | [Count Subarrays of Length Three with a Condition](https://leetcode.com/problems/count-subarrays-of-length-three-with-a-condition) | [Python](./Python/3392-count-subarrays-of-length-three-with-a-condition.py) | [Easy](./Readme/3392-count-subarrays-of-length-three-with-a-condition.md) |

Readme/2872-maximum-number-of-k-divisible-components.md

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<h2><a href="https://leetcode.com/problems/maximum-number-of-k-divisible-components/">2872. Maximum Number of K-Divisible Components</a></h2><h3>Hard</h3><hr><div><p>There is an undirected tree with <code>n</code> nodes labeled from <code>0</code> to <code>n - 1</code>. You are given the integer <code>n</code> and a 2D integer array <code>edges</code> of length <code>n - 1</code>, where <code>edges[i] = [a<sub>i</sub>, b<sub>i</sub>]</code> indicates that there is an edge between nodes <code>a<sub>i</sub></code> and <code>b<sub>i</sub></code> in the tree.</p>
1+
<h2><a href="https://leetcode.com/problems/maximum-number-of-k-divisible-components">3058. Maximum Number of K-Divisible Components</a></h2><h3>Hard</h3><hr><p>There is an undirected tree with <code>n</code> nodes labeled from <code>0</code> to <code>n - 1</code>. You are given the integer <code>n</code> and a 2D integer array <code>edges</code> of length <code>n - 1</code>, where <code>edges[i] = [a<sub>i</sub>, b<sub>i</sub>]</code> indicates that there is an edge between nodes <code>a<sub>i</sub></code> and <code>b<sub>i</sub></code> in the tree.</p>
22

33
<p>You are also given a <strong>0-indexed</strong> integer array <code>values</code> of length <code>n</code>, where <code>values[i]</code> is the <strong>value</strong> associated with the <code>i<sup>th</sup></code> node, and an integer <code>k</code>.</p>
44

@@ -8,17 +8,19 @@
88

99
<p>&nbsp;</p>
1010
<p><strong class="example">Example 1:</strong></p>
11-
<img alt="" src="https://assets.leetcode.com/uploads/2023/08/07/example12-cropped2svg.jpg" style="width: 1024px; height: 453px;">
12-
<pre><strong>Input:</strong> n = 5, edges = [[0,2],[1,2],[1,3],[2,4]], values = [1,8,1,4,4], k = 6
11+
<img alt="" src="https://assets.leetcode.com/uploads/2023/08/07/example12-cropped2svg.jpg" style="width: 1024px; height: 453px;" />
12+
<pre>
13+
<strong>Input:</strong> n = 5, edges = [[0,2],[1,2],[1,3],[2,4]], values = [1,8,1,4,4], k = 6
1314
<strong>Output:</strong> 2
1415
<strong>Explanation:</strong> We remove the edge connecting node 1 with 2. The resulting split is valid because:
1516
- The value of the component containing nodes 1 and 3 is values[1] + values[3] = 12.
1617
- The value of the component containing nodes 0, 2, and 4 is values[0] + values[2] + values[4] = 6.
1718
It can be shown that no other valid split has more than 2 connected components.</pre>
1819

1920
<p><strong class="example">Example 2:</strong></p>
20-
<img alt="" src="https://assets.leetcode.com/uploads/2023/08/07/example21svg-1.jpg" style="width: 999px; height: 338px;">
21-
<pre><strong>Input:</strong> n = 7, edges = [[0,1],[0,2],[1,3],[1,4],[2,5],[2,6]], values = [3,0,6,1,5,2,1], k = 3
21+
<img alt="" src="https://assets.leetcode.com/uploads/2023/08/07/example21svg-1.jpg" style="width: 999px; height: 338px;" />
22+
<pre>
23+
<strong>Input:</strong> n = 7, edges = [[0,1],[0,2],[1,3],[1,4],[2,5],[2,6]], values = [3,0,6,1,5,2,1], k = 3
2224
<strong>Output:</strong> 3
2325
<strong>Explanation:</strong> We remove the edge connecting node 0 with 2, and the edge connecting node 0 with 1. The resulting split is valid because:
2426
- The value of the component containing node 0 is values[0] = 3.
@@ -41,4 +43,3 @@ It can be shown that no other valid split has more than 3 connected components.
4143
<li>Sum of <code>values</code> is divisible by <code>k</code>.</li>
4244
<li>The input is generated such that <code>edges</code> represents a valid tree.</li>
4345
</ul>
44-
</div>
File renamed without changes.

0 commit comments

Comments
 (0)