結果

問題 No.79 過小評価ダメ・ゼッタイ
ユーザー torus711torus711
提出日時 2019-06-22 14:22:25
言語 Haskell
(9.6.2)
結果
AC  
実行時間 153 ms / 5,000 ms
コード長 880 bytes
コンパイル時間 11,565 ms
コンパイル使用メモリ 160,364 KB
実行使用メモリ 21,084 KB
最終ジャッジ日時 2023-08-27 02:46:59
合計ジャッジ時間 6,267 ms
ジャッジサーバーID
(参考情報)
judge13 / judge11
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 12 ms
11,404 KB
testcase_01 AC 143 ms
21,032 KB
testcase_02 AC 3 ms
7,260 KB
testcase_03 AC 2 ms
7,116 KB
testcase_04 AC 2 ms
7,156 KB
testcase_05 AC 42 ms
17,760 KB
testcase_06 AC 3 ms
7,100 KB
testcase_07 AC 3 ms
7,120 KB
testcase_08 AC 3 ms
7,084 KB
testcase_09 AC 2 ms
7,180 KB
testcase_10 AC 2 ms
7,172 KB
testcase_11 AC 2 ms
7,140 KB
testcase_12 AC 3 ms
7,132 KB
testcase_13 AC 2 ms
7,256 KB
testcase_14 AC 82 ms
16,664 KB
testcase_15 AC 32 ms
13,744 KB
testcase_16 AC 113 ms
19,772 KB
testcase_17 AC 32 ms
13,228 KB
testcase_18 AC 103 ms
19,820 KB
testcase_19 AC 73 ms
16,980 KB
testcase_20 AC 153 ms
21,064 KB
testcase_21 AC 6 ms
9,588 KB
testcase_22 AC 42 ms
15,284 KB
testcase_23 AC 122 ms
20,772 KB
testcase_24 AC 122 ms
21,084 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
Loaded package environment from /home/judge/.ghc/x86_64-linux-9.6.1/environments/default
[1 of 2] Compiling Main             ( Main.hs, Main.o )

Main.hs:35:1: warning: [GHC-94817] [-Wtabs]
    Tab character found here, and in 7 further locations.
    Suggested fix: Please use spaces instead.
   |
35 |         getLine
   | ^^^^^^^^
[2 of 2] Linking a.out

ソースコード

diff #

{-# LANGUAGE BangPatterns #-}
{-# LANGUAGE BinaryLiterals #-}
{-# LANGUAGE MultiWayIf #-}
{-# LANGUAGE NumDecimals #-}
{-# LANGUAGE ScopedTypeVariables #-}
{-# LANGUAGE TupleSections #-}

import Control.Applicative
import Control.Arrow
import Control.Monad
import Control.Monad.ST

import Data.Char
import Data.List
import Data.Maybe

import qualified Data.ByteString.Char8 as B

import Data.Array.ST.Safe
import Data.STRef

import Debug.Trace
import Text.Printf

import GHC.Exts

readInt = readLn :: IO Int
readInts = map ( fst . fromJust . B.readInt ) . B.words <$> B.getLine
readNInts = readInt >>= flip replicateM readInt

which a b f = if f then a else b
mp [ a, b ] = ( a, b )

main = do
	getLine
	ls <- reverse . sort <$> readInts
	let
		histogram = group ls
		maxLength = maximum $ map length histogram
	print $ head $ head $ filter ( ( == maxLength ) . length ) histogram
0