Fraction and decimal conversion
Starting with a/b, the converter divides a by b to obtain the decimal, provided b is not zero. When it creates or receives a fraction, common factors are canceled to express the ratio in lowest terms. For a terminating decimal, place value supplies the denominator: 0.375 is 375/1000, and dividing both terms by 125 gives 3/8.