-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathVector.h
More file actions
39 lines (30 loc) · 777 Bytes
/
Vector.h
File metadata and controls
39 lines (30 loc) · 777 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
34
35
36
37
38
39
#include <iostream>
#include <string>
#include <fstream>
using namespace std;
void menu();
class Vector {
protected:
double x;
double y;
public:
Vector() : x(0), y(0) {}
~Vector();
Vector(double x, double y);
};
class Overloading : public Vector
{
public:
Overloading operator = (const Overloading & other);
Overloading operator + (const Overloading & other);
Overloading operator - (const Overloading & other);
Overloading operator * (const Overloading & other);
Overloading operator / (const Overloading & other);
friend ostream & operator << ( ostream & os,const Overloading & other);
friend istream & operator >> (istream & os, Overloading & other);
};
class VectorB : public Overloading
{
private:
double B;
};