Welcome to the CHICKEN Scheme pasting service
date> and date< added by gahr on Sat Jan 28 20:15:59 2023
;; date.scm (import srfi-19 chicken.format) (let* ((today (current-date)) (yesterday (date-subtract-duration today (make-duration days: 1)))) (printf "~A ~A ~A\n" today (if (date<? today yesterday) "<" ">") yesterday) (printf "~A ~A ~A\n" today (if (date>? today yesterday) ">" "<") yesterday)) ;; csi -s date.scm #@2023-01-28T19:15:08Z < #@2023-01-27T19:15:08Z #@2023-01-28T19:15:08Z < #@2023-01-27T19:15:08Z