Website Summary Files Commits Branches @commit @diff @stats
path: root / homework / 0MI0800028 / Homework 02 / example.lisp
diff options
context:
space:
mode:
1 files changed, 21 insertions, 0 deletions
-rw-r--r--homework/0MI0800028/Homework 02/example.lisp21
diff --git a/homework/0MI0800028/Homework 02/example.lisp b/homework/0MI0800028/Homework 02/example.lisp
new file mode 100644
index 0000000..cd7a577
--- /dev/null
+++ b/homework/0MI0800028/Homework 02/example.lisp
@@ -0,0 +1,21 @@
+(defvar *NAME* "John")
+(defvar *AGE* 23)
+(defvar *ABOUT* " T NIL cond decf block")
+
+;;; This is a stupid funciton
+(defun adult? ()
+ (>= *AGE* 18))
+
+(defun will-I-graduate? ()
+ NIL)
+
+(defun distance (p1 p2)
+ (sqrt (* p1 p1) (* p2 p2)))
+
+(defun bar (a b)
+ (if (and (> b a) (<= 10 b))
+ (format t "Valid")
+ (format t "Invalid")))
+
+(defun foo (&key ((:apple a)) ((:box b) 0) ((:charlie c) 0 c-supplied-p))
+ (list a b c c-supplied-p))