In addition to David's comments. Sometimes the banging can be caused because the piping is improperly strapped and the faucet is a single lever type faucet. Since water is hydrolic (not compressible) when you start it moving towards the faucet, then shut it off, the water wants to continue traveling in that direction. But the faucet type does not allow for slow closing, therefore the force is stopped instantly. The result is the force has to be absorbed in the flexation of the piping. Most of the time it bangs against the wood where its been strapped or where it runs through the studs. A water hammer under the offending sink helps this problem. They make small ones that go on the supply lines for the faucet. In addition, sometimes the gasket inside the faucet is loose as David says and it bangs back into place with the water on, creating the same problem.