Submission #713821

#TimeUsernameProblemLanguageResultExecution timeMemory
713821ALTAKEXEBaloni (COCI15_baloni)C++14
0 / 100
165 ms7204 KiB
#include <bits/stdc++.h> using namespace std; int main() { //freopen("input.txt","r",stdin); long long int n,m,t=0; cin>>n; m=n; long long int a[n]; for(int i=0;i<n;i++) cin>>a[i]; for(int i=0;i<n;i++){ if(a[i]==m) m--; else{ t++; } } cout<<t; return 0; }
#Verdict Execution timeMemoryGrader output
Fetching results...