結果

問題 No.182 新規性の虜
ユーザー natoriusannatoriusan
提出日時 2023-07-30 10:50:36
言語 F#
(F# 4.0)
結果
AC  
実行時間 374 ms / 5,000 ms
コード長 410 bytes
コンパイル時間 8,047 ms
コンパイル使用メモリ 185,776 KB
実行使用メモリ 48,240 KB
最終ジャッジ日時 2024-04-17 12:14:02
合計ジャッジ時間 21,429 ms
ジャッジサーバーID
(参考情報)
judge1 / judge4
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 341 ms
34,724 KB
testcase_01 AC 339 ms
35,252 KB
testcase_02 AC 339 ms
35,128 KB
testcase_03 AC 341 ms
34,728 KB
testcase_04 AC 341 ms
34,864 KB
testcase_05 AC 341 ms
34,392 KB
testcase_06 AC 342 ms
34,724 KB
testcase_07 AC 340 ms
34,336 KB
testcase_08 AC 363 ms
43,380 KB
testcase_09 AC 374 ms
48,240 KB
testcase_10 AC 370 ms
46,720 KB
testcase_11 AC 365 ms
45,312 KB
testcase_12 AC 357 ms
38,600 KB
testcase_13 AC 342 ms
34,836 KB
testcase_14 AC 341 ms
35,320 KB
testcase_15 AC 336 ms
34,624 KB
testcase_16 AC 342 ms
34,472 KB
testcase_17 AC 341 ms
35,680 KB
testcase_18 AC 366 ms
43,904 KB
testcase_19 AC 361 ms
40,256 KB
testcase_20 AC 356 ms
38,456 KB
testcase_21 AC 371 ms
44,544 KB
testcase_22 AC 358 ms
39,284 KB
testcase_23 AC 338 ms
34,372 KB
testcase_24 AC 370 ms
47,488 KB
testcase_25 AC 367 ms
43,008 KB
testcase_26 AC 347 ms
37,300 KB
testcase_27 AC 339 ms
34,636 KB
evil01.txt AC 372 ms
49,904 KB
evil02.txt AC 372 ms
49,792 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
  復元対象のプロジェクトを決定しています...
  /home/judge/data/code/main.fsproj を復元しました (249 ms)。
MSBuild のバージョン 17.9.6+a4ecab324 (.NET)
  main -> /home/judge/data/code/bin/Release/net8.0/main.dll
  main -> /home/judge/data/code/bin/Release/net8.0/publish/

ソースコード

diff #

let n = stdin.ReadLine () |> int
let a = stdin.ReadLine().Split " " |> Array.map int |> Array.sort


[|
    for i in 0..a.Length-1 ->
        if a.Length = 1 then
            true
        elif i = 0 then
            a.[i] <> a.[i+1]
        elif i = a.Length-1 then
            a.[i] <> a.[i-1]
        else
            a.[i] <> a.[i-1] && a.[i] <> a.[i+1]
|] |> Array.filter id |> Array.length |> printfn "%d"
0