結果
問題 | No.1563 Same Degree |
ユーザー | siman |
提出日時 | 2021-06-27 10:44:58 |
言語 | Ruby (3.3.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 275 bytes |
コンパイル時間 | 868 ms |
コンパイル使用メモリ | 11,320 KB |
実行使用メモリ | 20,360 KB |
最終ジャッジ日時 | 2023-09-07 17:19:07 |
合計ジャッジ時間 | 4,622 ms |
ジャッジサーバーID (参考情報) |
judge12 / judge14 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 79 ms
15,012 KB |
testcase_01 | WA | - |
testcase_02 | WA | - |
testcase_03 | WA | - |
testcase_04 | WA | - |
testcase_05 | WA | - |
testcase_06 | WA | - |
testcase_07 | WA | - |
testcase_08 | WA | - |
testcase_09 | WA | - |
testcase_10 | WA | - |
testcase_11 | AC | 118 ms
17,584 KB |
testcase_12 | AC | 162 ms
18,252 KB |
testcase_13 | AC | 321 ms
20,360 KB |
testcase_14 | AC | 356 ms
20,176 KB |
testcase_15 | AC | 264 ms
20,276 KB |
コンパイルメッセージ
Main.rb:4: warning: assigned but unused variable - n Syntax OK
ソースコード
T = gets.to_i T.times do n, m = gets.split.map(&:to_i) counter = Hash.new(0) m.times do u, v = gets.split.map(&:to_i) counter[u] += 1 counter[v] += 1 end vs = counter.values if vs.size != vs.uniq.size puts 'Yes' else puts 'No' end end