test
This commit is contained in:
parent
37776af5db
commit
ab03d5f10c
4045 changed files with 286212 additions and 3 deletions
32
.config/Code/User/History/17d3e36f/7E4T.cpp
Normal file
32
.config/Code/User/History/17d3e36f/7E4T.cpp
Normal file
|
@ -0,0 +1,32 @@
|
|||
/*
|
||||
Rafay Ahmad
|
||||
23I-2526
|
||||
*/
|
||||
#include <iostream>
|
||||
using namespace std;
|
||||
|
||||
class BasicShape{
|
||||
double area;
|
||||
public:
|
||||
double getArea(){
|
||||
return area;
|
||||
}
|
||||
virtual void calcArea() = 0;
|
||||
};
|
||||
|
||||
class Circle : public BasicShape{
|
||||
long int centerX;
|
||||
long int centerY;
|
||||
double radius;
|
||||
public:
|
||||
Circle(long int centerX, long int centerY, double radius) : centerX(centerX), centerY(centerY){
|
||||
calcArea();
|
||||
}
|
||||
};
|
||||
|
||||
int main(){
|
||||
|
||||
|
||||
|
||||
return 0;
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue