結果

問題 No.1748 Parking Lot
ユーザー motoshiramotoshira
提出日時 2021-11-19 21:42:11
言語 Common Lisp
(sbcl 2.3.8)
結果
WA  
実行時間 -
コード長 1,437 bytes
コンパイル時間 921 ms
コンパイル使用メモリ 33,092 KB
実行使用メモリ 27,132 KB
最終ジャッジ日時 2023-08-30 07:51:10
合計ジャッジ時間 2,219 ms
ジャッジサーバーID
(参考情報)
judge15 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 8 ms
23,068 KB
testcase_01 AC 8 ms
22,976 KB
testcase_02 AC 10 ms
25,020 KB
testcase_03 AC 9 ms
23,024 KB
testcase_04 AC 9 ms
22,948 KB
testcase_05 AC 10 ms
25,064 KB
testcase_06 AC 8 ms
22,944 KB
testcase_07 AC 9 ms
22,952 KB
testcase_08 AC 8 ms
22,972 KB
testcase_09 AC 9 ms
23,024 KB
testcase_10 AC 9 ms
23,032 KB
testcase_11 AC 10 ms
25,056 KB
testcase_12 AC 10 ms
25,112 KB
testcase_13 AC 8 ms
23,060 KB
testcase_14 AC 10 ms
27,132 KB
testcase_15 AC 9 ms
22,956 KB
testcase_16 AC 10 ms
22,952 KB
testcase_17 AC 9 ms
25,096 KB
testcase_18 AC 9 ms
23,012 KB
testcase_19 AC 10 ms
27,036 KB
testcase_20 AC 9 ms
23,036 KB
testcase_21 AC 9 ms
25,088 KB
testcase_22 AC 9 ms
23,076 KB
testcase_23 WA -
権限があれば一括ダウンロードができます
コンパイルメッセージ
; compiling file "/home/judge/data/code/Main.lisp" (written 30 AUG 2023 07:51:07 AM):
; processing (IN-PACKAGE #:CL-USER)
; processing (DECLAIM (OPTIMIZE # ...))
; processing (DECLAIM (MUFFLE-CONDITIONS COMPILER-NOTE))
; processing (DISABLE-DEBUGGER)
; processing (PUSHNEW :INLINE-GENERIC-FUNCION ...)
; processing (IN-PACKAGE #:CL-USER)
; processing (DECLAIM (INLINE PRINTLN))
; processing (DEFUN PRINTLN ...)
; processing (DEFUN READ-INTO ...)
; processing (DEFUN MAIN ...)
; processing (MAIN)

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

ソースコード

diff #

(in-package #:cl-user)

;;------------------------------Preferences------------------------------

(eval-when (:compile-toplevel :load-toplevel :execute)
  #+swank (declaim (optimize (speed 3) (safety 2)))
  #-swank (declaim (optimize (speed 3) (safety 0) (debug 0)))
  #+swank (load "~/ghq/github.com/motoshira/atcoder-submission/ac-tools/act.lisp")
  #+swank (ql:quickload :prove)
  #-swank (declaim (sb-ext:muffle-conditions sb-ext:compiler-note))
  #-swank (sb-ext:disable-debugger)
  (pushnew :inline-generic-funcion *features*))

;;---------------------------------Body---------------------------------

(in-package #:cl-user)

(declaim (inline println))
(defun println (obj &optional (stream *standard-output*))
  (let ((*read-default-float-format* 'double-float))
    (prog1 obj
      (princ obj stream)
      (terpri stream))))

(defun read-into (count &optional (result-type 'list) (reader #'read))
  (coerce (loop :repeat count :collect (funcall reader)) result-type))

(defun main ()
  (let ((n (read))
        (k (read)))
    (println (if (= k (1- n))
                 n
                 (1- n)))))

#-swank (main)

#+swank
(defun run ()
  (let ((*standard-input*
          (make-string-input-stream
           (with-output-to-string (*standard-output*)
             (run-program
              (merge-pathnames "copy-or-paste" (truename "~/bin/"))
              '()
              :output *standard-output*)))))
    (main)))
0