Minggu, 30 Januari 2011
Heritage Shared
A few days ago, we posted two C++ quizzes based on a question posted in a forum. Let’s review the first question#include class Foo {public: virtual void DoStuff()=0; }; class Bar : public Foo {public: virtual void DoStuff(int a)=0;}; class Baz : public Bar {public: void DoStuff(int a) override { std::cout << "Baz::DoStuff(int)"; } void DoStuff() override
Langganan:
Posting Komentar (Atom)
Tidak ada komentar:
Posting Komentar