# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
115420 | 2019-06-07T11:25:14 Z | baqargam | Ancient Books (IOI17_books) | C++14 | 0 ms | 0 KB |
#include<bits/stdc++.h> #include "books.h" using namespace std; long long minimum_walk(std::vector<int> p, int s) { int n=p.size(); for(int i=n-1;i>=0;i--){ if(p[i]!=i) break; } return 2*i; }