Skip to content

Commit 0d5cac9

Browse files
committed
update docs now
1 parent a11b985 commit 0d5cac9

1 file changed

Lines changed: 8 additions & 4 deletions

File tree

library/math/matrix_related/xor_basis_ordered.hpp

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,14 @@
22
//! https://codeforces.com/blog/entry/68953
33
//! https://github.com/ssk4988/Hackpack/blob/main/content/numerical/XORBasis.h
44
//! @code
5-
//! basis_ordered<int> b1;
6-
//! basis_ordered<ll> b2;
7-
//! basis_ordered<bitset<lg>> b3;
8-
//! b2.insert(x); // 0 <= x < (1LL<<B)
5+
//! const int B = 30;
6+
//! xor_basis<B> b;
7+
//! bool in_span = b.shrink(x) >= 0;
8+
//! b.insert(x);
9+
//! bitset<B> k = 5; // 0 <= k < (1 << npivot)
10+
//! bitset<B> kth = b.walk(k);
11+
//! // (k+1)-th smallest vector in span
12+
//! // k=0 gives smallest vector in span
913
//! @endcode
1014
//! @time O(q * B^2/32)
1115
//! @space O(B^2/32)

0 commit comments

Comments
 (0)