結果
| 問題 |
No.2184 A○B問題
|
| コンテスト | |
| ユーザー |
siman
|
| 提出日時 | 2023-01-13 22:10:40 |
| 言語 | Ruby (3.4.1) |
| 結果 |
AC
|
| 実行時間 | 106 ms / 2,000 ms |
| コード長 | 253 bytes |
| コンパイル時間 | 316 ms |
| コンパイル使用メモリ | 7,680 KB |
| 実行使用メモリ | 12,416 KB |
| 最終ジャッジ日時 | 2024-12-24 17:44:00 |
| 合計ジャッジ時間 | 3,614 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 24 |
コンパイルメッセージ
Syntax OK
ソースコード
A = gets.split.map(&:to_i)
B = gets.split.map(&:to_i)
res = [*1..5]
temp = Array.new(5)
A.each_with_index do |a, i|
temp[i] = res[a - 1]
end
res = temp.dup
B.each_with_index do |b, i|
temp[i] = res[b - 1]
end
res = temp.dup
puts res.join(' ')
siman