Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migration of unmigrated content due to installation of a new plugin

...

Esimerkki 2. Moniperiytymisen ongelma.

CHevonen:

Code Block
class CHevonen
{
public:
    void Syo() {
    }
};

CLintu:

Code Block
class CLintu
{
public:
    void Syo() {
    }
};

CPegasus:

Code Block
class CPegasus :
    public CHevonen,
    public CLintu
{
};

main:

Code Block
int main()
{
    CPegasus pegasus;

    pegasus.Syo();
}

...