結果
| 問題 | No.188 HAPPY DAY |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2025-03-20 23:46:11 |
| 言語 | Common Lisp (sbcl 2.5.0) |
| 結果 |
AC
|
| 実行時間 | 8 ms / 1,000 ms |
| コード長 | 546 bytes |
| コンパイル時間 | 1,265 ms |
| コンパイル使用メモリ | 28,292 KB |
| 実行使用メモリ | 23,628 KB |
| 最終ジャッジ日時 | 2025-03-20 23:46:14 |
| 合計ジャッジ時間 | 1,237 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 1 |
コンパイルメッセージ
; compiling file "/home/judge/data/code/Main.lisp" (written 20 MAR 2025 11:46:12 PM): ; wrote /home/judge/data/code/Main.fasl ; compilation finished in 0:00:00.079
ソースコード
(defvar N)
(setq N 31)
(defvar sum)
(setq sum 0)
(defvar mon)
(loop for mon from 1 to 12 do
(case mon
( 1 (setq N 31) )
( 2 (setq N 28) )
( 3 (setq N 31) )
( 4 (setq N 30) )
( 5 (setq N 31) )
( 6 (setq N 30) )
( 7 (setq N 31) )
( 8 (setq N 31) )
( 9 (setq N 30) )
( 10 (setq N 31) )
( 11 (setq N 30) )
( 12 (setq N 31) )
)
(loop for i from 1 to N do
(if (eq mon (+ (floor i 10) (mod i 10))) (incf sum)))
)
(format 't "~d~%" sum)