resname.cpp
来自「《C/C++程序员实用大全》配套代码,适用初学C++的人员。」· C++ 代码 · 共 23 行
CPP
23 行
#include <iostream.h>
class Base
{
public:
void display(void) { cout << "This is the base class" << endl; };
};
class Derived: public Base
{
public:
void display(void) { cout << "This is the derived class" << endl; };
};
void main(void)
{
Derived my_class;
my_class.display();
my_class.Base::display();
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?