
5 Nov
2007
5 Nov
'07
7:02 p.m.
Hi, I'm was wondering how most people work during when designing a functional program. Do you create data structures/types first? Do you work from some type signatures? For example, take a blog. Is the first step likely to be something like: data BlogEntry = BlogEntry { title::String,content::String,comments::[Comment] } type Blog = [BlogEntry] or more likely thinking about what functions will be required: addEntry :: BlogEntry -> Blog -> Blog displayBlog :: Blog -> HTML displayEntry :: BlogEntry -> HTML I'm trying to get my brain out of thinking OO thinking more functionally. Thanks, Levi lstephen.wordpress.com