Delete newm.cpp
This commit is contained in:
parent
4cb52c15d0
commit
07883a9e3b
|
@ -1,29 +0,0 @@
|
||||||
#include<iostream>
|
|
||||||
using namespace std;
|
|
||||||
class a
|
|
||||||
{
|
|
||||||
public:
|
|
||||||
int A;
|
|
||||||
virtual void setA(int t)=0;
|
|
||||||
virtual int returnA()=0;
|
|
||||||
};
|
|
||||||
class b:public a
|
|
||||||
{
|
|
||||||
public:
|
|
||||||
void setA(int t)
|
|
||||||
{
|
|
||||||
A=t;
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
int returnA()
|
|
||||||
{
|
|
||||||
return A;
|
|
||||||
}
|
|
||||||
};
|
|
||||||
int main()
|
|
||||||
{
|
|
||||||
b m;
|
|
||||||
m.setA(1);
|
|
||||||
m.returnA();
|
|
||||||
return 0;
|
|
||||||
}
|
|
Loading…
Reference in New Issue