adding the perceptron code; still not passing all tests