Initial data commit
This commit is contained in:
parent
72d218235f
commit
f23f22d71c
199087 changed files with 3378941 additions and 0 deletions
16
Task/Date-format/Scheme/date-format.ss
Normal file
16
Task/Date-format/Scheme/date-format.ss
Normal file
|
|
@ -0,0 +1,16 @@
|
|||
(define short-date
|
||||
(lambda (lt)
|
||||
(strftime "%Y-%m-%d" (localtime lt))))
|
||||
|
||||
(define long-date
|
||||
(lambda (lt)
|
||||
(strftime "%A, %B %d, %Y" (localtime lt))))
|
||||
|
||||
(define main
|
||||
(lambda (args)
|
||||
;; Current date
|
||||
(let ((dt (car (gettimeofday))))
|
||||
;; Short style
|
||||
(display (short-date dt))(newline)
|
||||
;; Long style
|
||||
(display (long-date dt))(newline))))
|
||||
Loading…
Add table
Add a link
Reference in a new issue