aboutsummaryrefslogtreecommitdiff
path: root/2022/template.cl
diff options
context:
space:
mode:
Diffstat (limited to '2022/template.cl')
-rw-r--r--2022/template.cl18
1 files changed, 18 insertions, 0 deletions
diff --git a/2022/template.cl b/2022/template.cl
new file mode 100644
index 0000000..9ffb4a0
--- /dev/null
+++ b/2022/template.cl
@@ -0,0 +1,18 @@
+(defvar *prog-input*)
+
+(let ((ui (read-line)))
+ (if (equal ui "")
+ (setq *prog-input* *standard-input*)
+ (setq *prog-input* (open ui))))
+
+(let
+ ((cal (read-line *prog-input* NIL)) )
+
+ (loop until (or (equal cal "end") (not cal)) do
+ (setq cal (read-line *prog-input* NIL)))
+
+ (print 1))
+
+(if (not (eq *prog-input* *standard-input*))
+ (close *prog-input*))
+