Introduction - If you have any usage issues, please Google them yourself
Create a fractional class Rational, used to perform arithmetic operations for fractions, and write a program to test the class.
(1) the class has two member variables, that is, molecules and denominator, all of which are integral types
(2) define a constructor to initialize the class object. The constructor must reduce the input parameters. For example, if a given fraction is 2/4 (i.e. the molecule is 2, the denominator is 4), we need to reduce it to 1/2, and then store it in the corresponding member variable, that is, the molecule is 1 and the denominator is 2.
(3) a add member function is defined to implement the addition of two fractions, and the result should also be reduced.
(4) a sub member function is defined to implement a subtraction of two fractions, and the result is reduced form.