SGF parsing exercise for Haskell