home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
C/C++ Users Group Library 1996 July
/
C-C++ Users Group Library July 1996.iso
/
listings
/
v_11_03
/
1103107a
< prev
next >
Encoding:
Amiga
Atari
Commodore
DOS
FM Towns/JPY
Macintosh
Macintosh JP
Macintosh to JP
NeXTSTEP
RISC OS/Acorn
Shift JIS
UTF-8
Wrap
Text File
|
1993-01-06
|
335 b
|
35 lines
#include <iostream.h>
class B
{
public:
void f();
void g();
};
void B::f() { cout << "B::f()\n"; }
void B::g() { cout << "B::g()\n"; }
class D : public B
{
public:
void g();
};
void D::g() { cout << "D::g()\n"; }
int main()
{
B b;
b.f();
b.g();
D d;
d.f();
d.g();
return 0;
}