Skip to content

Instantly share code, notes, and snippets.

@9999years
Created June 8, 2019 02:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save 9999years/a3014a8a9d794760ffa73700da9608ea to your computer and use it in GitHub Desktop.
Save 9999years/a3014a8a9d794760ffa73700da9608ea to your computer and use it in GitHub Desktop.
#lang r5rs
(define-syntax push!
(syntax-rules (push!)
((push! x s)
(set! s (cons x s)))))
(define-syntax pop!
(syntax-rules (pop!)
((pop! s)
(let ((t (car s)))
(set! s (cdr s))
t))))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment