1. A method for programming neural networks having row and column arrays of resistive memory devices, said method comprising the steps of: initializing said resistive memory devices to a predetermined resistance value; determining whether a training status tracker indicates that an overall training process is completed; selecting a training pattern; inputting said training pattern to said arrays and outputting a resulting signal; detecting error by computing the difference between said output signal and an expected output signal value; determining whether said detected error is within a near zero threshold and if so, updating said training progress in said training status tracker; and returning to said step of determining whether said overall training process is completed; otherwise, generating programming signals and adjusting resistance states of said resistive memory devices in said arrays by applying said programming signals; resetting the training progress as in the status tracker; and returning to said step of determining whether said overall training process is completed.