Perceptron implementation in Java for Machine Learning Assignment