MCPcopy Create free account
hub / github.com/Vishruth-S/CompetitiveCode / gcd

Function gcd

Codeforces_problems/Bargain/solution.cpp:56–56  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

54template <typename T> T sqr(T x) { return x * x; }
55template <typename T> T abs(T x) { return x < 0 ? -x : x; }
56template <typename T> T gcd(T a, T b) { return b ? gcd(b, a % b) : a; }
57template <typename T> bool chmin(T &x, const T& y) { if (x > y) { x = y; return true; } return false; }
58template <typename T> bool chmax(T &x, const T& y) { if (x < y) { x = y; return true; } return false; }
59

Callers 1

printNcRFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected