Solution to convert fractional decimal to binary