結果
| 問題 |
No.275 中央値を求めよ
|
| コンテスト | |
| ユーザー |
Hirotaka Ohkubo
|
| 提出日時 | 2016-07-15 16:16:47 |
| 言語 | Haskell (9.10.1) |
| 結果 |
RE
|
| 実行時間 | - |
| コード長 | 234 bytes |
| コンパイル時間 | 1,817 ms |
| コンパイル使用メモリ | 177,924 KB |
| 実行使用メモリ | 8,320 KB |
| 最終ジャッジ日時 | 2024-10-15 01:11:29 |
| 合計ジャッジ時間 | 3,092 ms |
|
ジャッジサーバーID (参考情報) |
judge3 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | WA * 3 |
| other | AC * 6 WA * 28 RE * 4 |
コンパイルメッセージ
Loaded package environment from /home/judge/.ghc/x86_64-linux-9.8.2/environments/default [1 of 2] Compiling Main ( Main.hs, Main.o ) [2 of 2] Linking a.out
ソースコード
import Data.List main = do getLine li <- getLine let ns = sort $ map read $ words li print $ compute ns compute ns | odd (length ns) = ns !! (l2+1) | True = (ns !! l2 + ns !! (l2+1)) / 2 where l2 = div (length ns) 2
Hirotaka Ohkubo