Submission #298243

#TimeUsernameProblemLanguageResultExecution timeMemory
298243HemimorGondola (IOI14_gondola)C++14
20 / 100
20 ms1152 KiB
#include "gondola.h" #include <algorithm> #include <iostream> #include <iomanip> #include <numeric> #include <cassert> #include <vector> #include <cmath> #include <queue> #include <set> #include <map> #define syosu(x) fixed<<setprecision(x) using namespace std; typedef long long ll; typedef unsigned int uint; typedef unsigned long long ull; typedef pair<int,int> P; typedef pair<double,double> pdd; typedef pair<ll,ll> pll; typedef vector<int> vi; typedef vector<vi> vvi; typedef vector<double> vd; typedef vector<vd> vvd; typedef vector<ll> vl; typedef vector<vl> vvl; typedef vector<string> vs; typedef vector<P> vp; typedef vector<vp> vvp; typedef vector<pll> vpll; typedef pair<P,int> pip; typedef vector<pip> vip; const int inf=1<<30; const ll INF=1ll<<60; const double pi=acos(-1); const double eps=1e-8; const ll mod=1e9+7; const int dx[4]={-1,0,1,0},dy[4]={0,-1,0,1}; int valid(int n, int inputSeq[]){ int id=-1,x; for(int i=0;i<n;i++) if(inputSeq[i]<=n){ if(id==-1) id=i,x=inputSeq[i]; if((x+i-id-1)%n!=inputSeq[i]-1) return 0; } sort(inputSeq,inputSeq+n); for(int i=0;i<n-1;i++) if(inputSeq[i]==inputSeq[i+1]) return 0; return 1; } //---------------------- int replacement(int n, int gondolaSeq[], int replacementSeq[]){ /* for(int i=0;i<n;i++) if(gondolaSeq[i]>n){ }*/ return 0; } //---------------------- int countReplacement(int n, int inputSeq[]) { return -3; }
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...