mooyyu

M3 - 费马小定理-乘法逆元

c++11 math

template< class type >
type inverse(type a, type p) {
  return (type)qpow(a, p - 2, p);
}