Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Using this header to file to make a polynomial linked list in c++. I need the driver and the main. 1 ifndef POLYLINKH 2 #define

Using this header to file to make a polynomial linked list in c++. I need the driver and the main.

image text in transcribed

1 ifndef POLYLINKH 2 #define POLYLINKH - - - - #include 5 using namespace std; 7 class Node int coef; int expon; Node* next 10 12 13 14 15 16 17 18 19 20 21 22 class LinkedList //Constructors Node) Node (int coef); Node (int coef, int expon) Node (int coef, int expon, Node* n); //Friends friend class LinkedList; 24 25 public: 26 Node* head; //Constructors LinkedList); LinkedList (const LinkedList& p1); //Copy Constuctor LinkedList); 28 //Destructor 31 32 //Mutators void Insert(int coef, int expon); 34 35 //Accessors void Output ()const; 37 //Overload LinkedList operator+(const LinkedList& p1) LinkedList operator-(const LinkedList& p1); LinkedList& operator= (const LinkedList& LL); //Assignment operator friend istream& operator>>(istream& is, LinkedList& p1); friend ostream& operator 5 using namespace std; 7 class Node int coef; int expon; Node* next 10 12 13 14 15 16 17 18 19 20 21 22 class LinkedList //Constructors Node) Node (int coef); Node (int coef, int expon) Node (int coef, int expon, Node* n); //Friends friend class LinkedList; 24 25 public: 26 Node* head; //Constructors LinkedList); LinkedList (const LinkedList& p1); //Copy Constuctor LinkedList); 28 //Destructor 31 32 //Mutators void Insert(int coef, int expon); 34 35 //Accessors void Output ()const; 37 //Overload LinkedList operator+(const LinkedList& p1) LinkedList operator-(const LinkedList& p1); LinkedList& operator= (const LinkedList& LL); //Assignment operator friend istream& operator>>(istream& is, LinkedList& p1); friend ostream& operator

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

More Books

Students also viewed these Databases questions