__init__the constructorfor the line polynomial([ ,- ]__str__for doing print( __call__to enable the call ( __add__to make work __mul__to allow * in additionthe class needs method differentiate that computes the derivative of polynomialand changes it in-place starting with the most basic methodsthe constructor is fairly straightforward and the call method simply follows the recipe from class polynomialdef __init__(selfcoefficients)self coeff coefficients def __call__(selfx) for in range(len(self coeff)) +self coeff[ ]* ** return to enable the addition of two polynomialswe need to implement the __add__ methodwhich should take one argument in addition to self the method should return new polynomial instancesince the sum of two polynomials is polynomialand the method needs to implement the rules of polynomial addition adding two polynomials means to add terms of equal orderwhichin our list representationmeans to loop over the self coeff lists and add individual elementsas followsclass polynomialdef __add__(selfother)return self other start with the longest list and add in the otherif len(self coefflen(other coeff)coeffsum self coeff[:copyfor in range(len(other coeff))coeffsum[ +other coeff[ielsecoeffsum other coeff[:copyfor in range(len(self coeff))coeffsum[ +self coeff[ireturn polynomial(coeffsumthe order of the sum of two polynomials is equal to the highest order of the twoso the length of the returned polynomial must be equal to the length of the longest of the two coeff lists we utilize this knowledge in the code by starting with copy of the longest list and then looping through the shortest and adding to each element