Magicloud Magiclouds <[email protected]> writes: > Hi, > I am working on some calendar GUI thing. And I cannot find a library > to operate the "date". > Like, when `now <- getZonedTime`, how could I get all the dates of > the week. Or when I got `today`, how to get the date of 10 days ago?
This sort of thing (given now <- getZonedTime): take 10 $ map (addDays (-1)) $ repeat $ utctDay $ zonedTimeToUTC now there's enough functions in that to be going on with, I think. -- Jón Fairbairn [email protected] http://www.chaos.org.uk/~jf/Stuff-I-dont-want.html (updated 2009-01-31) _______________________________________________ Haskell-Cafe mailing list [email protected] http://www.haskell.org/mailman/listinfo/haskell-cafe
