Always use type signatures.
Solution for problem 2: butLast.
Try using pattern matching instead of compose.
Add solution to problem 3: elementAt.
Use guard to autorun specs.
Add spec for elementAt index out of bounds.