結果

問題 No.443 GCD of Permutation
ユーザー Ysmr_RyYsmr_Ry
提出日時 2016-11-17 00:54:48
言語 Haskell
(9.8.2)
結果
TLE  
実行時間 -
コード長 135 bytes
コンパイル時間 4,059 ms
コンパイル使用メモリ 158,384 KB
実行使用メモリ 16,732 KB
最終ジャッジ日時 2023-08-17 07:46:18
合計ジャッジ時間 7,060 ms
ジャッジサーバーID
(参考情報)
judge11 / judge13
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 6 ms
15,308 KB
testcase_01 AC 3 ms
7,256 KB
testcase_02 AC 2 ms
7,184 KB
testcase_03 AC 6 ms
11,012 KB
testcase_04 AC 61 ms
12,312 KB
testcase_05 AC 2 ms
6,976 KB
testcase_06 AC 3 ms
7,188 KB
testcase_07 AC 5 ms
10,964 KB
testcase_08 AC 3 ms
7,684 KB
testcase_09 AC 5 ms
10,892 KB
testcase_10 AC 2 ms
7,124 KB
testcase_11 AC 5 ms
10,960 KB
testcase_12 AC 2 ms
7,360 KB
testcase_13 AC 2 ms
7,252 KB
testcase_14 TLE -
testcase_15 -- -
testcase_16 -- -
testcase_17 -- -
testcase_18 -- -
testcase_19 -- -
testcase_20 -- -
testcase_21 -- -
testcase_22 -- -
testcase_23 -- -
testcase_24 -- -
testcase_25 -- -
testcase_26 -- -
testcase_27 -- -
testcase_28 -- -
testcase_29 -- -
testcase_30 -- -
testcase_31 -- -
権限があれば一括ダウンロードができます
コンパイルメッセージ
Loaded package environment from /home/judge/.ghc/x86_64-linux-9.6.1/environments/default
[1 of 2] Compiling Main             ( Main.hs, Main.o )
[2 of 2] Linking a.out

ソースコード

diff #

import Data.List(permutations)

main :: IO ()
main = do
  n <- getLine
  print $ foldl gcd 0 $ (map read $ permutations n :: [Integer])
0