結果
| 問題 |
No.1716 Bonus Nim
|
| コンテスト | |
| ユーザー |
siman
|
| 提出日時 | 2021-10-25 17:02:10 |
| 言語 | Ruby (3.4.1) |
| 結果 |
AC
|
| 実行時間 | 604 ms / 2,000 ms |
| コード長 | 243 bytes |
| コンパイル時間 | 55 ms |
| コンパイル使用メモリ | 7,552 KB |
| 実行使用メモリ | 37,376 KB |
| 最終ジャッジ日時 | 2024-10-03 10:40:01 |
| 合計ジャッジ時間 | 9,927 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 1 |
| other | AC * 26 |
コンパイルメッセージ
Syntax OK
ソースコード
T = gets.to_i
T.times do
n = gets.to_i
a = gets.split.map(&:to_i).sort
if n.even?
cnt = a.each_slice(2).count { |x, y| x != y }
if cnt > 0
puts 'Alice'
else
puts 'Bob'
end
else
puts 'Alice'
end
end
siman