Segregate 0s and 1s