Calling methods of a virtual member class
问题 I know how virtual works in the context of member functions, but I saw an article online about virtual member classes that confuses me. The example I found is this: class Machine { void run () {} virtual class Parts { }; }; // The inner class "Parts" of the class "Machine" may return the number of wheels the machine has. class Car: public Machine { void run() { cout << "The car is running." << endl; } class Parts { int get_Wheels () { cout << "A car has 4 wheels." << endl; return 4; } string