# | TimeUTC-0 | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
26579 | wwiiiii | 주유소 (KOI16_gas) | C++14 | 1008 ms | 51900 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include <cstdio>
#include <vector>
#include <algorithm>
#include <queue>
using namespace std;
class edge {
public:
long long v, c;//vertex, cost
bool operator<(const edge & next) const {
if (c != next.c) return c > next.c;
else return v > next.v;
}
};
const long long vmax = 2520, emax = 4020, inf = vmax * emax * vmax;
long long n, m;
long long oil[vmax];
vector<edge> graph[vmax];
long long road[vmax][vmax];
void dijk(long long start)
{
vector<long long> d(n + 1, inf);
priority_queue<edge> pq;
pq.push({ start, 0 });
while (!pq.empty())
{
edge now = pq.top(); pq.pop();
if (now.c > d[now.v]) continue;
Compilation message (stderr)
# | 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... |