Simple perceptron implementation on Haskell