Severity: Warning

Message: count(): Parameter must be an array or an object that implements Countable

Filename: controllers/calculator.php

Line Number: 37

- 1-800-665-6601
- info@tutorpace.com

Given decimal number: 1.25

In order to convert a decimal to its fraction form, first count the number of places to the right side after the decimal point.

1.25 has ‘2’ places after the decimal point.

Hence multiply and divide by the number with 2 zeroes (1.25 * 100)/100

Now simplify this fraction to its simplest form we can divide the fraction by ‘25’.

(125/25)/ (100/25) = (5/4)

Given decimal number: 2.5

In order to convert a decimal to its fraction form, first count the number of places to the right side after the decimal point.

2.5 has ‘1’ place after the decimal point.

Hence multiply and divide by the number with 1 zero (2.5 * 10)/10

Now simplify this fraction to its simplest form we can divide the fraction by ‘5’.

(25/5)/ (10/5) =(5/2)