# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
233403 | priyansh5525 | Strange Device (APIO19_strange_device) | C++17 | 623 ms | 60016 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<bits/stdc++.h>
using namespace std;
#define ll long long int
#define pii pair<long long int,long long int>
#define vi vector<long long int >
#define vvi vector<vector< long long int>>
#define MP make_pair
#define PB push_back
#define pb pop_back
#define PF push_front
#define pf pop_front
#define MOD 1000000007
int main()
{
ios_base::sync_with_stdio(false);
cin.tie(NULL);
ll n,a,b;
vector<pii> vec;
cin>>n>>a>>b;
for(ll i=0;i<n;i++)
{
ll x,y;
cin>>x>>y;
vec.PB(MP(x,y));
}
// solve equation t2 = x*fac+t1
ll fac = a/__gcd(a,b+1);
fac*=b;
if(fac<=0)
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |