結果

問題 No.182 新規性の虜
ユーザー カルロスカルロス
提出日時 2016-05-24 13:41:37
言語 Ruby
(3.3.0)
結果
RE  
実行時間 -
コード長 223 bytes
コンパイル時間 43 ms
コンパイル使用メモリ 7,552 KB
実行使用メモリ 18,816 KB
最終ジャッジ日時 2024-04-16 11:49:16
合計ジャッジ時間 4,270 ms
ジャッジサーバーID
(参考情報)
judge4 / judge3
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 93 ms
12,160 KB
testcase_01 AC 89 ms
12,032 KB
testcase_02 AC 94 ms
12,160 KB
testcase_03 RE -
testcase_04 RE -
testcase_05 RE -
testcase_06 RE -
testcase_07 RE -
testcase_08 RE -
testcase_09 RE -
testcase_10 RE -
testcase_11 RE -
testcase_12 RE -
testcase_13 AC 91 ms
12,160 KB
testcase_14 AC 95 ms
12,160 KB
testcase_15 AC 90 ms
12,288 KB
testcase_16 AC 89 ms
12,032 KB
testcase_17 AC 89 ms
12,160 KB
testcase_18 AC 128 ms
16,896 KB
testcase_19 AC 116 ms
15,616 KB
testcase_20 AC 109 ms
13,824 KB
testcase_21 AC 132 ms
17,280 KB
testcase_22 AC 109 ms
14,592 KB
testcase_23 AC 88 ms
12,288 KB
testcase_24 RE -
testcase_25 AC 135 ms
18,688 KB
testcase_26 RE -
testcase_27 AC 90 ms
12,032 KB
evil01.txt RE -
evil02.txt RE -
権限があれば一括ダウンロードができます
コンパイルメッセージ
Syntax OK

ソースコード

diff #

novelty = Array.new(10001, 0)
n = gets.to_i
data = gets.split.map(&:to_i)
n.times{|i|
    novelty[data[i]] = novelty[data[i]] + 1
}

ans = 0
(1..10000).each{|i|
    if novelty[i]==1
        ans = ans + 1
    end
}
puts ans
0