Skip to content

Commit 30b988e

Browse files
committed
add more KACTL macros
1 parent 5d6e3a1 commit 30b988e

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

library/math/matrix_related/row_reduce.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
//! affected by row operations
99
//! @time O(n * m * min(cols, n))
1010
//! @space O(1)
11-
pii row_reduce(vector<vector<int>>& mat, int cols) {
11+
pii row_reduce(vector<vi>& mat, int cols) {
1212
int n = sz(mat), m = sz(mat[0]), rank = 0;
1313
int det = 1;
1414
for (int col = 0; col < cols && rank < n; col++) {

library/math/matrix_related/solve_linear_mod.hpp

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,8 @@
1212
//! @space O(m)
1313
struct solve_linear_mod {
1414
int rank, det;
15-
vector<int> sol;
16-
solve_linear_mod(vector<vector<int>>& mat,
17-
const vector<int>& rhs) {
15+
vi sol;
16+
solve_linear_mod(vector<vi>& mat, const vi& rhs) {
1817
int n = sz(mat), m = sz(mat[0]);
1918
rep(i, 0, n) mat[i].push_back(rhs[i]);
2019
tie(rank, det) = row_reduce(mat, m);

0 commit comments

Comments
 (0)