結果

問題 No.99 ジャンピング駒
ユーザー neko_the_shadow
提出日時 2017-02-12 23:52:07
言語 Scheme
(Gauche-0.9.15)
結果
AC  
実行時間 187 ms / 5,000 ms
コード長 317 bytes
コンパイル時間 82 ms
コンパイル使用メモリ 5,248 KB
実行使用メモリ 32,640 KB
最終ジャッジ日時 2024-12-29 17:04:25
合計ジャッジ時間 2,951 ms
ジャッジサーバーID
(参考情報)
judge1 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 6
権限があれば一括ダウンロードができます

ソースコード

diff #

(define (solve)
    (let* ((n (string->number (read-line)))
           (numbers (map string->number (string-split (read-line) #\space))))
        (let ((odd-cnt (count odd? numbers))
              (even-cnt (count even? numbers)))
            (abs (- odd-cnt even-cnt)))))

(begin
    (display (solve))
    (newline))
0