# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
945917 | teacup | Fancy Fence (CEOI20_fancyfence) | C++17 | 67 ms | 7904 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 int long long
#define ii pair<int,int>
typedef vector<int> vi;
#define iii tuple<int,int,int>
typedef vector<ii> vii;
typedef vector<iii> viii;
typedef map<int,int> mii;
#ifndef debug
#define cerr if (0) cerr
#endif
int N,H[100005],W[100005];
int pref[100005], last_mins[100005];
const int mod=1e9+7;
int nc2(int n){
return ((n*(n-1))/2)%mod;
}
int rect(int h, int w){
return (nc2(h+1)*nc2(w+1))%mod;
}
int32_t main(){
cin>>N;
int last_min = -1;
for (int i=0; i<N; i++)cin>>H[i];
for (int i=0; i<N; i++){
cin>>W[i];
if (i==0) pref[i]=W[i];
else pref[i]=W[i]+pref[i-1];
# | 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... |