hello-world-lib.scm 461 B

123456789101112131415161718192021222324
  1. ;; IMPORTANT!
  2. ;; The module must be named exactly like the name of the file it is in.
  3. (define-module (hello-world-lib)
  4. #:export (hello
  5. world
  6. exclamation-mark))
  7. ;; IMPORTANT!
  8. ;; use-modules comes AFTER the module definition!
  9. (use-modules (srfi srfi-9)
  10. (srfi srfi-9 gnu))
  11. (define hello
  12. (λ ()
  13. (display "hello")))
  14. (define world
  15. (λ ()
  16. (display "world")))
  17. (define exclamation-mark
  18. (λ ()
  19. (display "!")))