Hydrogen can be prepared by the electrolysis of water.
Electrolysis of water: Splitting of water into hydrogen(H2) and oxygen (O2) gases by passing an electric current through it.
2H2O(l)2H2(g)+ O2(g)
Thus, the statement is true as hydrogen can be prepared by electrolysis of water