結果

問題 No.35 タイパー高橋
ユーザー kuuso1kuuso1
提出日時 2016-08-19 01:09:23
言語 F#
(F# 4.0)
結果
AC  
実行時間 322 ms / 5,000 ms
コード長 622 bytes
コンパイル時間 7,752 ms
コンパイル使用メモリ 189,288 KB
実行使用メモリ 35,556 KB
最終ジャッジ日時 2024-04-25 09:04:53
合計ジャッジ時間 9,084 ms
ジャッジサーバーID
(参考情報)
judge5 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 312 ms
35,124 KB
testcase_01 AC 315 ms
34,744 KB
testcase_02 AC 315 ms
35,280 KB
testcase_03 AC 322 ms
35,556 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
  復元対象のプロジェクトを決定しています...
  /home/judge/data/code/main.fsproj を復元しました (289 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 #

open System
type Sol() =
    member this.Solve() = 
        let N = stdin.ReadLine() |> int
        let S = Array.zeroCreate<int*string> N
        for i = 0 to (N-1) do
           S.[i] <- stdin.ReadLine().Split() |> (fun ss -> (int ss.[0]) , (ss.[1]) )
        
        let f (n,s) =
            let canType = 12 * n /1000
            let toType = Seq.length s
            if toType <= canType then toType else canType
        
        let types = S |> Array.sumBy f 
        let tot = S |> Array.sumBy (fun (n,s) -> Seq.length s )
        printfn "%d %d" types (tot - types)
        
let mySol = new Sol()
mySol.Solve()
0