Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

programming c++. need help plz. I already have a problem, which is as follow: De

ID: 3768016 • Letter: P

Question

programming c++.

need help plz.

I already have a problem, which is as follow:

Develop a program that works with Polynomials. The internal representation of a polynomial is an array: each element that stores the coefficients and the index of the array determines the exponents. Have the user enter a string as follows for the polynomial (^ refers to the power of) -4x^0 + x^1 + 4x^3 - 3x^4 this polynomial has the second element (exponent 1) of coefficient array store 1. Similarly the third term is stored as coefficient 4 in the 4th element (index and exponent 3). The third element for exponent 2 has a coefficient of 0 since the term doesn’t exist. use a pointer and dynamic memory allocation for the array of each polynomial. This will require for you to take the polynomial string and figure out the highest exponent in the polynomial. Parsing the string for the substring x^, you can figure out the coefficient and the exponent. So the above polynomial will result in an array of size 5 as follows: -4 1 0 4 -3

If you are unable to parse a string to extract the coefficient and exponent, then simply ask the user for the highest exponent and then allocate memory for the array using this exponent value. Then ask the user for the coefficient and exponent for each term and store it in the dynamic array of integers. The driver program (main part of the program) should ask the user to enter two polynomials (specify to the user how the polynomial should be entered, use the specified format above) and then give a choice to do the following:

(1) Addition

(2) Subtraction

(3) Multiplication

(4) Exit

Requirenments: or ( what I need help solving) is the following problem:

Could you please modify that polynomial problem to make it into a class and provided overloaded operators. The internal representation of a polynomial is an array: one which stores the coefficients and the index of the array determines the exponents. For example, the polynomial (^ refers to the power of) -4x^0 + x^1 + 4x^3 - 3x^4 Develop a polynomial class with proper constructor and destructor functions as well other member functions for the inputting and printing the polynomial (the polynomial should be printed as shown above in the example). The class should also provide the following overloaded operator capabilities: Overload the addition (+) operator to add two polynomials Overload the subtraction (-) operator to subtract two polynomials Overload the assignment (=) operator to assign one polynomial to another Overload the multiplication operator (*) to multiply two polynomials The driver program (main part of the program) should ask the user to enter two Polynomials (specify to the user how the polynomial should be entered) and then give a choice to do the following: (1) Addition (2) Subtraction (3) Multiplication (4) Assignment (5) Exit

Print the polynomials and the resulting polynomial of the operation after each operation is performed. The polynomial should be printed using the format above. The program should continue until the user wants to exit. Also, the program should provide the user with the option to enter two new polynomials before exiting.

Explanation / Answer

program :

#include<stdio.h>