#include "reverse.h"
std::vector<long long> reverse(std::vector<long long> a) {
std::vector<long long> res(a.size());
for(int i = a.size() - 1; i >= 0; i--){
res[i] = a[a.size() - 1 - i];
}
return res;
}
# |
결과 |
실행 시간 |
메모리 |
Grader output |
1 |
Correct |
2 ms |
256 KB |
Output is correct |
2 |
Correct |
2 ms |
256 KB |
Output is correct |
3 |
Correct |
2 ms |
256 KB |
Output is correct |
4 |
Correct |
2 ms |
384 KB |
Output is correct |
5 |
Correct |
0 ms |
256 KB |
Output is correct |
6 |
Correct |
2 ms |
384 KB |
Output is correct |
7 |
Correct |
4 ms |
640 KB |
Output is correct |
8 |
Correct |
15 ms |
1000 KB |
Output is correct |
9 |
Correct |
15 ms |
2048 KB |
Output is correct |
10 |
Correct |
41 ms |
5864 KB |
Output is correct |