結果
問題 | No.2674 k-Walk on Bipartite |
ユーザー | tour2st |
提出日時 | 2024-03-15 23:13:50 |
言語 | C++14 (gcc 12.3.0 + boost 1.83.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 658 bytes |
コンパイル時間 | 887 ms |
コンパイル使用メモリ | 97,896 KB |
実行使用メモリ | 16,320 KB |
最終ジャッジ日時 | 2024-03-15 23:13:56 |
合計ジャッジ時間 | 4,553 ms |
ジャッジサーバーID (参考情報) |
judge13 / judge14 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | WA | - |
testcase_01 | AC | 4 ms
8,512 KB |
testcase_02 | WA | - |
testcase_03 | AC | 4 ms
8,512 KB |
testcase_04 | AC | 4 ms
8,512 KB |
testcase_05 | AC | 4 ms
8,512 KB |
testcase_06 | AC | 4 ms
8,512 KB |
testcase_07 | AC | 106 ms
12,992 KB |
testcase_08 | WA | - |
testcase_09 | WA | - |
testcase_10 | WA | - |
testcase_11 | WA | - |
testcase_12 | WA | - |
testcase_13 | WA | - |
testcase_14 | WA | - |
testcase_15 | AC | 199 ms
16,320 KB |
testcase_16 | WA | - |
testcase_17 | AC | 142 ms
14,272 KB |
testcase_18 | WA | - |
testcase_19 | WA | - |
testcase_20 | WA | - |
testcase_21 | AC | 178 ms
14,656 KB |
testcase_22 | WA | - |
testcase_23 | AC | 4 ms
8,512 KB |
testcase_24 | WA | - |
testcase_25 | WA | - |
testcase_26 | AC | 4 ms
8,512 KB |
testcase_27 | WA | - |
testcase_28 | AC | 4 ms
8,512 KB |
testcase_29 | AC | 4 ms
8,512 KB |
testcase_30 | WA | - |
testcase_31 | AC | 4 ms
8,512 KB |
testcase_32 | WA | - |
testcase_33 | WA | - |
testcase_34 | AC | 4 ms
8,512 KB |
testcase_35 | WA | - |
testcase_36 | AC | 4 ms
8,512 KB |
testcase_37 | AC | 4 ms
8,512 KB |
testcase_38 | WA | - |
ソースコード
#include <iostream> #include <vector> #include <algorithm> #include <stack> #include <queue> #include <set> #include <map> #include <random> #include <time.h> #include <map> using namespace std; int n,m,s,t,k,a,b; vector<int>e[200000]; int length[200000]; bool visited[200000]; void dfs(int now, int len=0) { if(visited[now]) return; visited[now]=true; length[now]=len; for(int nxt:e[now]) dfs(nxt, len+1); } int main() { cin >> n >> m >> s >> t >> k; for(int i=0;i<m;i++) { cin >> a >> b; a--;b--; e[a].push_back(b); e[b].push_back(a); } s--;t--; dfs(s); cout << "No" << endl; }