Fuzion supports fraction types with all the standard numeric operations.
Here is a small example declaring two fractions and performing basic arithmetic operations on them:
Fractions are based on any integer type, in this case on
Fractions suffer from the value limitations of their underlying integer types. See this example:
Using a larger integer type solves the overflow:
int as the base type avoids overflow altogether: