fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. class klasa_1
  5. {
  6. public:
  7. void metoda_1() { cout<<"Yes"<<endl; }
  8. };
  9.  
  10. class klasa_2:public klasa_1
  11. {
  12. public:
  13. void metoda_2()
  14. {
  15. klasa_1::metoda_1();
  16. klasa_2::metoda_1();
  17. this->metoda_1();
  18. metoda_1();
  19. }
  20. };
  21.  
  22. int main()
  23. {
  24. klasa_2 k;
  25. k.metoda_2();
  26. return 0;
  27. }
Success #stdin #stdout 0s 3456KB
stdin
Standard input is empty
stdout
Yes
Yes
Yes
Yes