@sig("a"/ H[(Integral, "a")] >> "a" >> t(Ratio, "a"))
def toRatio(num, denom):
    """
    toRatio :: Integral a => a -> a -> Ratio a

    Conversion to Ratio.
    """
    frac = fractions.Fraction(num, denom)
    return R(frac.numerator, frac.denominator)
dataset/ETHPy150Open billpmurphy/hask/hask/Data/Num.py/toRatio/swapped operands of `/`