結果
問題 | No.7 プライムナンバーゲーム |
ユーザー | zazaboon |
提出日時 | 2017-01-29 11:06:39 |
言語 | Ruby (3.3.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 201 bytes |
コンパイル時間 | 106 ms |
コンパイル使用メモリ | 11,448 KB |
実行使用メモリ | 24,272 KB |
最終ジャッジ日時 | 2023-08-25 14:34:39 |
合計ジャッジ時間 | 7,510 ms |
ジャッジサーバーID (参考情報) |
judge15 / judge11 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | WA | - |
testcase_01 | WA | - |
testcase_02 | TLE | - |
testcase_03 | -- | - |
testcase_04 | -- | - |
testcase_05 | -- | - |
testcase_06 | -- | - |
testcase_07 | -- | - |
testcase_08 | -- | - |
testcase_09 | -- | - |
testcase_10 | -- | - |
testcase_11 | -- | - |
testcase_12 | -- | - |
testcase_13 | -- | - |
testcase_14 | -- | - |
testcase_15 | -- | - |
testcase_16 | -- | - |
コンパイルメッセージ
Syntax OK
ソースコード
require 'prime' n = gets.chomp.to_i c = 0 while(n > 0) c += 1 if(Prime.prime?(n)) break elsif(Prime.prime?(n-1)) c += 1 break end end p (c%2 == 1)? "Win":"Lose"