head and tail matches Haskell semantics, closes #21