Simplified solution to problem 23 in python.
Added solution to problem 23 in haskell.