Modifying count example

svn: r834
This commit is contained in:
Jay McCarthy 2005-09-11 20:01:33 +00:00
parent 8572e70968
commit 15300b37a4

View File

@ -5,10 +5,13 @@
(let ([count 0]
[date (date->string (seconds->date (current-seconds)) 'time-too)])
(unit/sig () (import servlet^)
(define other-count 0)
(set! other-count (add1 other-count))
(set! count (add1 count))
`(html (head (title "Counter"))
(body ([bgcolor "white"])
(p "This servlet was called " ,(number->string count)
" times and " ,(number->string other-count)
" times since loaded on " ,date ".")))))