Condensed code + fixed testing  break bug?

For some reason when switching the number of nodes when creating two
subsequent FF neural networks. breaks the second network, so it does
not get far into running. I tried to solve this. I have yet to see if
it works.