結果
問題 | No.998 Four Integers |
ユーザー | guricerin |
提出日時 | 2020-03-01 11:07:21 |
言語 | F# (F# 4.0) |
結果 |
AC
|
実行時間 | 55 ms / 1,000 ms |
コード長 | 1,107 bytes |
コンパイル時間 | 6,179 ms |
コンパイル使用メモリ | 166,880 KB |
実行使用メモリ | 24,576 KB |
最終ジャッジ日時 | 2023-08-20 19:17:37 |
合計ジャッジ時間 | 7,250 ms |
ジャッジサーバーID (参考情報) |
judge13 / judge12 |
(要ログイン)
テストケース
テストケース表示入力 | 結果 | 実行時間 実行使用メモリ |
---|---|---|
testcase_00 | AC | 53 ms
22,396 KB |
testcase_01 | AC | 55 ms
22,412 KB |
testcase_02 | AC | 54 ms
22,524 KB |
testcase_03 | AC | 54 ms
24,496 KB |
testcase_04 | AC | 55 ms
22,524 KB |
testcase_05 | AC | 54 ms
24,452 KB |
testcase_06 | AC | 53 ms
24,412 KB |
testcase_07 | AC | 54 ms
20,464 KB |
testcase_08 | AC | 53 ms
22,396 KB |
testcase_09 | AC | 54 ms
24,576 KB |
testcase_10 | AC | 53 ms
22,508 KB |
testcase_11 | AC | 53 ms
22,472 KB |
testcase_12 | AC | 53 ms
22,336 KB |
testcase_13 | AC | 53 ms
22,504 KB |
testcase_14 | AC | 53 ms
22,604 KB |
testcase_15 | AC | 55 ms
22,516 KB |
testcase_16 | AC | 54 ms
22,508 KB |
testcase_17 | AC | 54 ms
24,400 KB |
testcase_18 | AC | 54 ms
22,476 KB |
testcase_19 | AC | 55 ms
24,544 KB |
testcase_20 | AC | 54 ms
22,612 KB |
testcase_21 | AC | 55 ms
22,468 KB |
testcase_22 | AC | 52 ms
22,408 KB |
testcase_23 | AC | 54 ms
22,496 KB |
testcase_24 | AC | 53 ms
22,472 KB |
コンパイルメッセージ
Microsoft (R) F# Compiler version 11.0.0.0 for F# 5.0 Copyright (c) Microsoft Corporation. All Rights Reserved.
ソースコード
open System open System.Collections.Generic [<AutoOpen>] module Cin = let read f = stdin.ReadLine() |> f let reada f = stdin.ReadLine().Split() |> Array.map f let readChars() = read string |> Seq.toArray let readInts() = readChars() |> Array.map (fun x -> Convert.ToInt32(x.ToString())) [<AutoOpen>] module Cout = let writer = new IO.StreamWriter(new IO.BufferedStream(Console.OpenStandardOutput())) let print (s: string) = writer.Write s let println (s: string) = writer.WriteLine s let inline puts (s: ^a) = string s |> println // ----------------------------------------------------------------------------------------------------- // ----------------------------------------------------------------------------------------------------- let main() = let a = reada int |> Array.sort let mutable ok = true for i in 0 .. 2 do if a.[i] + 1 <> a.[i + 1] then ok <- false if ok then "Yes" else "No" |> puts () // ----------------------------------------------------------------------------------------------------- main() writer.Dispose()