# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
920927 | 2024-02-03T07:57:06 Z | salmon | Ancient Books (IOI17_books) | C++14 | 0 ms | 0 KB |
#include "books.h" long long minimum_walk(std::vector<int> p, int s) { long long sum = 0; for(int i = 0; i < N; i++){ sum += abs(p[i] - i); } return sum + 2; }