1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 `#include #include #include using namespace std; const uint32_t Max = 200000; int main() { uint32_t i, j, n, m, d; uint64_t t[Max], lastEnd, waitTime; cin >> n >> m; for (i=0; i> t[i]; } for (i=0; i> d; lastEnd = 0; waitTime = 0; for (j=0; j