Problem
(a) Design a Rational abstract type, whose values are rational numbers m/n. Equip your abstract type with operations such as construction from a given pair of integers m and n, addition, subtraction, multiplication, equality test, and comparison (‘‘is less than'').
(b) Implement your abstract type, representing each rational number by a pair of integers (m, n).
(c) Modify your implementation, representing each rational number by a pair of integers with no common factor. What are the advantages and disadvantages of this modified representation?