이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include <bits/stdc++.h>
#include <utility>
#include "overtaking.h"
#define ll long long
using namespace std;
int roadLength;
vector<int> sortingStationsPositions;
class bus {
public:
ll departingTime;
int speed;
bus(ll departingTimeP, int speedP) {
departingTime = departingTimeP;
speed = speedP;
}
};
vector<bus> buses;
void init(int L, int N, vector<ll> T, vector<int> W, int X, int M, vector<int> S) {
roadLength = L, sortingStationsPositions = std::move(S);
for (int i = 0; i < N; ++i) {
buses.emplace_back(T[i], W[i]);
}
buses.emplace_back(0, X);
}
long long arrival_time(long long Y) {
return Y + (ll)roadLength * (ll)buses.back().speed;
}
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|
Fetching results... |