(define-library (hello)
  (import (scheme base))
  (begin
    (define (main args)
      (write-string "Hello, ")
      (write-string (if (pair? (cdr args)) (cadr args) "world!"))
      (newline))
    (define (bye args)
      (write-string "Goodbye, ")
      (write-string (if (pair? (cdr args)) (cadr args) "world!"))
      (newline))))
