library

This documentation is automatically generated by online-judge-tools/verification-helper

View the Project on GitHub gyouzasushi/library

:heavy_check_mark: Group: XOR
(algebra/group_xor.hpp)

Depends on

Verified with

Code

#pragma once
#include "algebra/monoid_xor.hpp"
template <class T>
struct group_xor : monoid_xor<T> {
    static T inv(T a) {
        return a;
    }
};
#line 2 "algebra/monoid_xor.hpp"
template <class T>
struct monoid_xor {
    using S = T;
    static S op(S a, S b) {
        return a ^ b;
    }
    static S e() {
        return T(0);
    }
};
#line 3 "algebra/group_xor.hpp"
template <class T>
struct group_xor : monoid_xor<T> {
    static T inv(T a) {
        return a;
    }
};
Back to top page