package math.polynomials;

import math.utils.ArrayUtil;
import math.utils.Util;

public class Poly09 {
    public static void main(String[] args) {
        //degree, size, sort, reduce
        Jdm a1 = new Jdm(3, "x", 2);
        Jdm a2 = new Jdm(2, "x", 1);
        Jdm a3 = new Jdm(-2, "x", 2);
        Jdm a4 = new Jdm(1, "x", 0);
        Jdm[] arr = {a1, a2, a3, a4};
        ArrayUtil.print(arr);
        Poly poly = new Poly(arr);
        poly.reduce(new MaxFirstComp());
        System.out.println(poly);
        System.out.println("size: " + poly.size());
        System.out.println("stopień: " + poly.degree());
        //isFullPoly
        boolean t = poly.isFullPoly();
        Util.print(t);
    }
}
