Handle repeating decimals in strings
mainFraction.js supports repeating decimals using parentheses or single quotes to denote the repeating part. This allows for exact rational representation of numbers that would otherwise be imprecise in floating-point.
Supported syntax examples:
"0.(3)"or"0.'3'"for $0.333...$"123.45(6)"for $123.45666...$"123.45'6'"for $123.45666...$"123.(456)"for $123.456456...$
var f = new Fraction("123.32");
// Dividing by a repeating decimal string
console.log(f.div("33.6(567)"));