-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathPolynomials.h
More file actions
33 lines (26 loc) · 838 Bytes
/
Polynomials.h
File metadata and controls
33 lines (26 loc) · 838 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
/*@Author
* Student Name: Esin Ece Aydın
* Student ID: 150160151
* Date: 23.03.2019
*/
//Decleration of Polynomials
#ifndef _polynomials_
#define _polynomials_
#include<iostream>
class Polynomials{
int degree;
int *coeff;
int sizeP;
public:
Polynomials(int=0); // defaul constructor
Polynomials(int, int *);
~Polynomials(); //destructor
int getsize() const { //getter method to get sizeP
return sizeP;
}
void operator+(const Polynomials&) const;
void operator*(const Polynomials&) const;
friend std::ostream & operator << (std::ostream &out, const Polynomials &p); //friend function for Polynomials class
//it can access all members of this class.
};
#endif