The following properties and methods are available for the fractions class:
- numerator: This returns the numerator in the lowest term.
- denominator: This returns the denominator in the lowest term.
- from_float(float): This is constructor that takes a float type and creates a fraction representing the exact value of the argument. It's generally easier to just make a fraction instance directly from a float.
- from_decimal(dec): This is a constructor that takes a decimal instance and creates a fraction representing the exact value of the argument. It's generally easier to just make a fraction instance directly from a decimal instance.
- limit_denominator(max=1000000): This returns the closest fraction to the argument that has a denominator ...