fork(1) download
  1. #include<iostream>
  2. using namespace std;
  3. class A
  4. {
  5. public:
  6. int a;
  7. void method()
  8. {
  9. cout<<&A::method<<"\n";
  10. }
  11. };
  12.  
  13. int main()
  14. {
  15. A a1,a2,a3;
  16. a1.method();
  17. a2.method();
  18. a3.method();
  19. return 0;
  20. }
Success #stdin #stdout 0.01s 5544KB
stdin
Standard input is empty
stdout
1
1
1