# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
1107158 | ASN49K | Boat (APIO16_boat) | C++14 | 143 ms | 34184 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;
using i64=long long;
#define int i64
#define UNUSED -1
#define all(x) x.begin(),x.end()
#define pb push_back
const int mod=1e9+7,inf=1e9+1;
const i64 INF=1e18;
mt19937 rng(69);
int prod(int x,int y)
{
return (1LL*x*y)%mod;
}
int add(int x,int y)
{
assert(y>=0 && y<mod && x<mod);
return (x+y)%mod;
}
int pw2(int a,int p)
{
int rez=1;
while(p>0)
{
if(p&1)
{
rez=prod(rez,a);
}
p>>=1;
a=prod(a,a);
Compilation message (stderr)
# | 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... |