To use energy of flowing water large dams are built in hilly regions to store huge amount of water at a height. The stored water from high level in dam is carried through pipes to the turbine at the bottom of the dam and runs hydropower plant.
Similarly, the wind energy is used to generate electricity. For the same purpose, the rotatory motion of windmill is used to tum the turbine of the electric generator.