結果
| 問題 |
No.1229 ラグビーの得点パターン
|
| コンテスト | |
| ユーザー |
nononaga
|
| 提出日時 | 2020-09-22 11:01:24 |
| 言語 | Ruby (3.4.1) |
| 結果 |
AC
|
| 実行時間 | 97 ms / 2,000 ms |
| コード長 | 269 bytes |
| コンパイル時間 | 169 ms |
| コンパイル使用メモリ | 7,424 KB |
| 実行使用メモリ | 12,416 KB |
| 最終ジャッジ日時 | 2024-06-25 22:02:17 |
| 合計ジャッジ時間 | 4,280 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 4 |
| other | AC * 25 |
コンパイルメッセージ
Syntax OK
ソースコード
n=gets.to_i
pattern = 0
34.times do |pgCount|
21.times do |tCount|
(tCount+1).times do |gCount|
if n == pgCount * 3 + tCount * 5 + gCount * 2
pattern += 1
break
end
end
end
end
puts pattern
nononaga