# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
762632 | goodbyehanbyeol | Organizing the Best Squad (FXCUP4_squad) | C++17 | 30 ms | 61488 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include "squad.h"
#include <bits/stdc++.h>
#define mabs(x) ((x)>0?(x):(-x))
#pragma GCC optimize("O3")
#pragma GCC optimize("Ofast")
#pragma GCC optimize("unroll-loops")
using namespace std;
typedef long long ll;
ll gcd(ll x, ll y){
if(!y) return x;
return gcd(y, x%y);
}
struct Frac{
ll a, b;
Frac(){a=0, b=1;}
Frac(ll x){
a=x, b=1;
}
Frac(ll _a, ll _b){
a = _a, b = _b;
if(b<0) a=-a,b=-b;
ll g = gcd(mabs(a), mabs(b));
a /= g, b /= g;
}
Frac operator+(const Frac &r)const{
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |