[Solved] What would be the code to add and subtract fractions in c++ [closed]


a/b - c/d = (ad - bc) / bd

Then you need to reduce that to lowest terms (if you care about that).

solved What would be the code to add and subtract fractions in c++ [closed]