# | 제출 시각UTC-0 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
334471 | ncduy0303 | Hotspot (NOI17_hotspot) | C++17 | 827 ms | 250988 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
#include <bits/stdc++.h>
using namespace std;
#define ar array
#define ll long long
const int MAX_N = 5e3 + 1;
const int MOD = 1e9 + 7;
const int INF = 1e9;
const ll LINF = 1e18;
int n, m, k;
vector<int> adj[MAX_N];
ll dist[MAX_N][MAX_N], cnt[MAX_N][MAX_N];
double p[MAX_N];
void bfs(int s) {
queue<ar<int,2>> q;
q.push({0, s});
dist[s][s] = 0; cnt[s][s] = 1;
while (!q.empty()){
auto [d, u] = q.front(); q.pop();
if (d > dist[s][u]) continue;
for (int v : adj[u]) {
if (dist[s][v] > dist[s][u] + 1) {
dist[s][v] = dist[s][u] + 1;
cnt[s][v] = cnt[s][u];
q.push({dist[s][v], v});
}
컴파일 시 표준 에러 (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... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |