結果

問題 No.36 素数が嫌い!
ユーザー LeonardoneLeonardone
提出日時 2015-12-06 07:32:04
言語 Ruby
(3.3.0)
結果
WA  
実行時間 -
コード長 189 bytes
コンパイル時間 227 ms
コンパイル使用メモリ 11,452 KB
実行使用メモリ 15,688 KB
最終ジャッジ日時 2023-10-12 16:33:58
合計ジャッジ時間 8,427 ms
ジャッジサーバーID
(参考情報)
judge11 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 320 ms
15,392 KB
testcase_01 AC 105 ms
15,420 KB
testcase_02 AC 88 ms
15,284 KB
testcase_03 WA -
testcase_04 AC 88 ms
15,092 KB
testcase_05 WA -
testcase_06 WA -
testcase_07 WA -
testcase_08 AC 92 ms
15,224 KB
testcase_09 WA -
testcase_10 AC 88 ms
15,192 KB
testcase_11 WA -
testcase_12 WA -
testcase_13 WA -
testcase_14 AC 92 ms
15,512 KB
testcase_15 AC 89 ms
15,200 KB
testcase_16 WA -
testcase_17 RE -
testcase_18 WA -
testcase_19 AC 128 ms
15,352 KB
testcase_20 AC 119 ms
15,484 KB
testcase_21 AC 217 ms
15,484 KB
testcase_22 AC 105 ms
15,548 KB
testcase_23 AC 97 ms
15,424 KB
testcase_24 AC 230 ms
15,364 KB
testcase_25 AC 261 ms
15,476 KB
testcase_26 WA -
testcase_27 WA -
testcase_28 WA -
testcase_29 WA -
権限があれば一括ダウンロードができます
コンパイルメッセージ
Syntax OK

ソースコード

diff #

#! ruby
# yukicoder My Practice
# author: Leonardone @ NEETSDKASU

require "prime"

n = gets.to_i

ps = n.prime_division

c = ps.transpose[0].inject(:+)

ans = c > 2 ? :YES : :NO

puts ans
0