結果

問題 No.5 数字のブロック
ユーザー MiyamonYMiyamonY
提出日時 2019-09-02 19:56:11
言語 Scheme
(Gauche-0.9.14)
結果
RE  
実行時間 -
コード長 234 bytes
コンパイル時間 141 ms
コンパイル使用メモリ 5,360 KB
実行使用メモリ 13,568 KB
最終ジャッジ日時 2023-08-22 13:45:47
合計ジャッジ時間 2,599 ms
ジャッジサーバーID
(参考情報)
judge11 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 17 ms
11,608 KB
testcase_01 AC 17 ms
11,676 KB
testcase_02 RE -
testcase_03 AC 22 ms
12,924 KB
testcase_04 AC 21 ms
12,668 KB
testcase_05 AC 24 ms
13,136 KB
testcase_06 AC 22 ms
12,564 KB
testcase_07 AC 22 ms
12,556 KB
testcase_08 AC 22 ms
12,768 KB
testcase_09 AC 18 ms
12,004 KB
testcase_10 AC 25 ms
13,468 KB
testcase_11 AC 21 ms
12,360 KB
testcase_12 AC 23 ms
12,784 KB
testcase_13 AC 24 ms
13,212 KB
testcase_14 AC 17 ms
11,820 KB
testcase_15 AC 18 ms
11,676 KB
testcase_16 AC 24 ms
13,172 KB
testcase_17 AC 26 ms
13,568 KB
testcase_18 AC 25 ms
13,340 KB
testcase_19 AC 26 ms
13,496 KB
testcase_20 RE -
testcase_21 RE -
testcase_22 RE -
testcase_23 AC 17 ms
11,764 KB
testcase_24 AC 17 ms
11,656 KB
testcase_25 AC 17 ms
11,752 KB
testcase_26 RE -
testcase_27 RE -
testcase_28 RE -
testcase_29 AC 21 ms
12,512 KB
testcase_30 AC 19 ms
12,264 KB
testcase_31 RE -
testcase_32 RE -
testcase_33 RE -
権限があれば一括ダウンロードができます

ソースコード

diff #

(define (solve l arr)
  (define top (car arr))
  (if (< l top)
      0
      (+ 1 (solve (- l top) (cdr arr)))))

(let* ((l (read))
       (n (read))
       (arr (map (lambda (_) (read))
		 (iota n))))
  (print (solve l (sort arr))))
0