implement code to build neural network