peterdrake, In #Python, I can define a class Fraction to represent a rational number. I can then create one with Fraction(2, 3).
Is there a way to overload a construction operator so I can say something like 2 ./. 3 instead?
peterdrake, In #Python, I can define a class Fraction to represent a rational number. I can then create one with Fraction(2, 3).
Is there a way to overload a construction operator so I can say something like 2 ./. 3 instead?
Add comment