a demo for how to reverse bits of input