結果

問題 No.2922 Rose Garden
ユーザー Common Lisp
提出日時 2024-10-17 21:45:39
言語 Common Lisp
(sbcl 2.5.0)
結果
AC  
実行時間 155 ms / 3,000 ms
コード長 353 bytes
コンパイル時間 294 ms
コンパイル使用メモリ 37,124 KB
実行使用メモリ 34,740 KB
最終ジャッジ日時 2024-10-17 21:45:46
合計ジャッジ時間 5,940 ms
ジャッジサーバーID
(参考情報)
judge2 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 50
権限があれば一括ダウンロードができます
コンパイルメッセージ
; compiling file "/home/judge/data/code/Main.lisp" (written 17 OCT 2024 09:45:39 PM):

; wrote /home/judge/data/code/Main.fasl
; compilation finished in 0:00:00.005

ソースコード

diff #

(defun main ()
  (let* ((n (read))
         (s (read))
         (b (read))
         (h (read))
         (xs (loop repeat (1- n) collect (read)))
         (m h))
    (loop for a in xs
          if (> a (+ m (* b s)))
            do (progn (princ "No") (terpri) (return-from main))
          do (setq m (max m a)))
    (princ "Yes")
    (terpri)))
(main)
0