Solution to binary gap