[Haskell-beginners] how to implement accesor function for given data type