結果

問題 No.513 宝探し2
ユーザー LeonardoneLeonardone
提出日時 2017-05-05 23:35:58
言語 Haskell
(9.8.2)
結果
RE  
実行時間 -
コード長 366 bytes
コンパイル時間 1,920 ms
コンパイル使用メモリ 155,524 KB
実行使用メモリ 24,252 KB
平均クエリ数 2.92
最終ジャッジ日時 2023-09-23 13:50:13
合計ジャッジ時間 1,985 ms
ジャッジサーバーID
(参考情報)
judge12 / judge14
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 37 ms
23,352 KB
testcase_01 AC 24 ms
23,652 KB
testcase_02 AC 24 ms
24,036 KB
testcase_03 AC 24 ms
23,364 KB
testcase_04 AC 26 ms
23,664 KB
testcase_05 AC 26 ms
23,640 KB
testcase_06 AC 26 ms
24,252 KB
testcase_07 AC 26 ms
23,616 KB
testcase_08 RE -
testcase_09 AC 24 ms
23,364 KB
testcase_10 AC 24 ms
23,364 KB
testcase_11 AC 24 ms
23,400 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 )
[2 of 2] Linking a.out

ソースコード

diff #

-- Try yukicoder
-- author: Leonardone @ NEETSDKASU

import System.IO

main = do
    let maxlen = 100000
    putStrLn "0 0"
    hFlush stdout
    len0 <- read <$> getLine
    putStrLn $ "0 " ++ show maxlen
    hFlush stdout
    len1 <- read <$> getLine
    let x = (len0 + len1 - maxlen) `div` 2
    let y = len0 - x
    putStrLn $ show x ++ " " ++ show y
    

    
0