List of words

Ashley Yakeley ashley@semantic.org
Wed, 2 May 2001 01:42:55 -0700


At 2001-05-02 01:34, Hannah Schroeter wrote:

>How about this:
>
>import Char(toUpper)
>
>capitalize :: String -> String
>capitalize [] = []
>capitalize (c:cs) = toUpper c : cs
>
>capitalizeList :: [String] -> [String]
>capitalizeList = map capitalize

...or if you prefer...

capitalizeList :: [String] -> [String]
capitalizeList = map (map toUpper)


-- 
Ashley Yakeley, Seattle WA