[Haskell-cafe] n00b question: defining datatype

Jake McArthur jake.mcarthur at gmail.com
Thu Jul 23 14:45:11 EDT 2009

Iain Barnett wrote:
> data Task = Task { title :: String, completed :: Bool, subtasks :: [Task] }

This one looks the best to me. Remember, you can just use an empty list 
if the task has no subtasks.

- Jake

More information about the Haskell-Cafe mailing list