Your job is to choose a data structure to implement polynomials whose coefficients are positive integers, such as 17x^4+4x^3+0x^2+6x+12x^0
Here are three possible implementations.
I. As a two-dimensional array boolean values: coeff [c] [i] is true if and only if c * x^i is a tem of the polynomial.
II. As a tree map with Integer keys and values. Ifcx is a tem of the polynomial, then we added the following correspondence to the map: coeff.put (new Integer (i), new Integer (c)
III As a hash set of objects of type
public class Termi //based on power public int hashcode (... public Boolean equals (Object obj).. private int coefficient; //based on power private int power