This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defclass being () | |
((health :accessor health :initarg :health) | |
(injury :accessor injury :initarg :injury))) | |
(defmethod make-load-form ((being being) &optional environment) | |
(declare (ignore environment)) | |
`(make-instance ',(class-name (class-of being)) | |
:health ,(health being) | |
:injury ,(injury being))) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defpackage #:bijective-numeration | |
(:nicknames :bij) | |
(:use #:common-lisp) | |
(:export #:*base20-en* | |
#:*base26-en* | |
#:*base30-en* | |
#:*base36-en* | |
#:*digits*) | |
(:export #:weight | |
#:digit |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class WordB20 | |
Base20 = %w( B C D F G H J K L M N P Q R S T V W X Z ) | |
def self.random_b20(word_size) | |
word_chars = [] | |
word_size.times do | |
word_chars << Base20.sample | |
end | |
word_chars.join("") | |
end |
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
╷╷ | |
└┘ | |
╶┐┌╴ | |
┌┘└┐ | |
│┌┐│ | |
└┘└┘ | |
╷┌─┐┌─┐╷ | |
└┘┌┘└┐└┘ | |
┌┐└┐┌┘┌┐ | |
│└─┘└─┘│ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;;; History | |
(defun make-history () | |
(let (history) | |
(lambda (&optional event) | |
(when (and event | |
(not (equalp event (first history)))) | |
(push event history)) | |
(first history)))) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defun pr (obj &optional (str *standard-output*)) | |
(princ o str) | |
str) | |
;;; ... it becomes possible to chain `pr' expressions together: | |
;; (pr "!" (pr "world" (pr " " (pr "hello")))) | |
;;; This means, with a little convenience function (like `format'): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<fieldset> | |
<legend>What gender of address would you prefer we use in communications?</legend> | |
<ul> | |
<li> | |
<input type="radio" | |
name="preferred-gender-personal-address" | |
value="none" | |
checked/> | |
<label for="none">None</label> | |
</li> |
NewerOlder