diff options
Diffstat (limited to 'content/math/transforms/bitwiseTransforms.cpp')
| -rw-r--r-- | content/math/transforms/bitwiseTransforms.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/content/math/transforms/bitwiseTransforms.cpp b/content/math/transforms/bitwiseTransforms.cpp index 28561da..fbe3792 100644 --- a/content/math/transforms/bitwiseTransforms.cpp +++ b/content/math/transforms/bitwiseTransforms.cpp @@ -4,8 +4,8 @@ void bitwiseConv(vector<ll>& a, bool inv = false) { for (int i = 0; i < n; i += 2 * s) { for (int j = i; j < i + s; j++) { ll& u = a[j], &v = a[j + s]; - tie(u, v) = inv ? pair(v - u, u) : pair(v, u + v); // AND - //tie(u, v) = inv ? pair(v, u - v) : pair(u + v, u); //OR + u = inv ? u - v : u + v; // AND + //v = inv ? v - u : v + u; // OR //tie(u, v) = pair(u + v, u - v); // XOR }}} //if (inv) for (ll& x : a) x /= n; // XOR (careful with MOD) |
