Skip to content

Commit 2c458eb

Browse files
KKT89claude
andcommitted
refactor: move weighted_union_find from graph/ to data_structure/
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent b447d76 commit 2c458eb

9 files changed

Lines changed: 13 additions & 16 deletions

File tree

docsrc/library/graph/weighted_union_find.md renamed to docsrc/library/data_structure/weighted_union_find.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,11 @@ int r = uf.find(x); // x の根
2323
## Code
2424
2525
```cpp
26-
--8<-- "include/graph/weighted_union_find.hpp"
26+
--8<-- "include/data_structure/weighted_union_find.hpp"
2727
```
2828

2929
## Bundled (Copy & Paste)
3030

3131
```cpp
32-
--8<-- "bundled/graph/weighted_union_find.hpp"
32+
--8<-- "bundled/data_structure/weighted_union_find.hpp"
3333
```

docsrc/library/index.md

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,13 @@
99
- [Lowest Common Ancestor](tree/lowest_common_ancestor.md)
1010
- [Auxiliary Tree (Virtual Tree)](tree/auxiliary_tree.md)
1111

12+
## Data Structure
13+
14+
- [重み付き Union-Find](data_structure/weighted_union_find.md)
15+
1216
## Graph
1317

1418
- [Bellman Ford (負閉路検出)](graph/bellman_ford.md)
15-
- [重み付き Union-Find](graph/weighted_union_find.md)
1619

1720
## String
1821

docsrc/verify/aizu/3327.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
## Target Library
66

7-
- [Weighted Union Find](../../library/graph/weighted_union_find.md)
7+
- [Weighted Union Find](../../library/data_structure/weighted_union_find.md)
88

99
## Judge
1010

docsrc/verify/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
## Aizu
66

7-
-[AOJ 3327 - Beam Beam Beam](aizu/3327.md) — 2026-02-28
7+
-[AOJ 3327 - Beam Beam Beam](aizu/3327.md) — 2026-03-03
88

99
## Library Checker
1010

File renamed without changes.

include/string/z_algorithm.hpp

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,6 @@
33
#include <string>
44
#include <vector>
55

6-
/// @brief Z アルゴリズム
7-
///
8-
/// z[i] = s と s[i..] の最長共通接頭辞の長さ(z[0] = n)を O(n) で求める。
9-
/// std::string / std::vector<T> の両方に対応。
10-
///
11-
/// @param s 入力列
12-
/// @return z 配列(長さ n、z[0] = n)
136
template <class Container>
147
std::vector<int> z_algorithm(const Container& s) {
158
const int n = (int)s.size();

mkdocs.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,9 +82,10 @@ nav:
8282
- Tree:
8383
- Lowest Common Ancestor: library/tree/lowest_common_ancestor.md
8484
- Auxiliary Tree (Virtual Tree): library/tree/auxiliary_tree.md
85+
- Data Structure:
86+
- 重み付き Union-Find: library/data_structure/weighted_union_find.md
8587
- Graph:
8688
- Bellman Ford (負閉路検出): library/graph/bellman_ford.md
87-
- 重み付き Union-Find: library/graph/weighted_union_find.md
8889
- String:
8990
- Z Algorithm: library/string/z_algorithm.md
9091
- Verify:

verify/aizu/3327.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
using namespace std;
33
typedef long long int ll;
44

5-
#include "graph/weighted_union_find.hpp"
5+
#include "data_structure/weighted_union_find.hpp"
66

77
int main() {
88
ios::sync_with_stdio(false);

verify/status.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
"title": "Lowest Common Ancestor"
77
},
88
"verify/aizu/3327.cpp": {
9-
"bundled_hash": "sha256:4ed1498d39b78be0c3931458ba15123f77adffd21c83c9696b6ac62e0db9c4ae",
10-
"verified_at": "2026-02-28T07:07:23+09:00",
9+
"bundled_hash": "sha256:5277afa20d29e708e3aff74b81e0b3db5ffb3b37d2e42b80aa1ae0e4c24cfee5",
10+
"verified_at": "2026-03-03T00:03:21+09:00",
1111
"judge_url": "https://onlinejudge.u-aizu.ac.jp/challenges/sources/VPC/HUPC/3327?year=2023",
1212
"title": "AOJ 3327 - Beam Beam Beam"
1313
}

0 commit comments

Comments
 (0)