結果

問題 No.677 10^Nの約数
ユーザー kuuso1kuuso1
提出日時 2018-04-27 22:51:48
言語 F#
(F# 4.0)
結果
AC  
実行時間 93 ms / 2,000 ms
コード長 578 bytes
コンパイル時間 7,294 ms
コンパイル使用メモリ 166,892 KB
実行使用メモリ 25,160 KB
最終ジャッジ日時 2023-09-10 06:39:06
合計ジャッジ時間 8,186 ms
ジャッジサーバーID
(参考情報)
judge14 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 87 ms
25,048 KB
testcase_01 AC 93 ms
20,968 KB
testcase_02 AC 91 ms
25,160 KB
testcase_03 AC 91 ms
22,996 KB
testcase_04 AC 90 ms
21,132 KB
testcase_05 AC 91 ms
23,092 KB
testcase_06 AC 91 ms
23,184 KB
testcase_07 AC 91 ms
23,200 KB
testcase_08 AC 91 ms
25,120 KB
testcase_09 AC 92 ms
23,084 KB
testcase_10 AC 92 ms
23,192 KB
testcase_11 AC 91 ms
23,056 KB
testcase_12 AC 92 ms
23,012 KB
testcase_13 AC 92 ms
23,084 KB
testcase_14 AC 92 ms
23,084 KB
testcase_15 AC 91 ms
21,012 KB
testcase_16 AC 92 ms
23,180 KB
testcase_17 AC 92 ms
23,148 KB
testcase_18 AC 93 ms
22,944 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Microsoft (R) F# Compiler version 11.0.0.0 for F# 5.0
Copyright (c) Microsoft Corporation. All Rights Reserved.

ソースコード

diff #

open System

let ri () = stdin.ReadLine() |> int
let ria () = stdin.ReadLine().Split() |> Array.map int

type Sol() =
    member this.Solve() = 
        
        let N = ri()
        let rec pow n k = 
          match k with
            | 0 -> 1L
            | _ -> (int64) n * pow n  (k - 1)
        
        let a = [ for i in 0..N do
                    for j in 0..N do
                      yield (pow 2 i) * (pow 5 j) ]
        
        a
        |> List.sort
        |> List.iter (fun n -> printfn "%d" n)
        
        
        ()
let mySol = new Sol()
mySol.Solve()
0