Breaking the bonds between hydrogen and oxygen in water requires exactly the same amount of energy as can be released by re-combining (burning) hydrogen with oxygen.
However, nothing is 100.00000000 percent efficient. Electrical resistance in the wiring, mechanical friction, and the like, rob some of the energy produced. Internal combustion engines are at best, about 40 percent efficient at converting the potential energy of combustion into mechanical work.
"Suppose that you add a generator to the motor and us that electricity to break down more water into Hydrogen and Oxygen? Won't THAT fix the problem?" No. Suppose that you have an electrolysis cell capable of converting 100 percent of the electrical energy to breaking the hydrogen and oxygen bonds. You feed 2 KW of electrical energy into it from the generator. You lose some of the 2 KW due to resistance in the wiring. So, 1.95 KW worth of H2 and O2 are produced. That goes to the IC engine. A little more energy is lost because of friction in the tubing, so 1.94 KW of fuel and oxygen gets to the engine. Since the internal combustion engine is only 40% efficient, you end up with 0.97 KW output from the generator. IF you feed 100 percent of this energy into the generator, since IT is only about 85% efficient, you get about 0.82 KW out, to feed the Hydrogen generator. And, the downward spiral continues. Wihthin seconds, you aren't producing enough gas to keep the engine running, and everything comes to a halt...