fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. class Function {
  5. public:
  6. Function() {
  7. cout << "Function created!" << endl;
  8. }
  9. };
  10.  
  11. void Function() {
  12. cout << "Function called" << endl;
  13. }
  14.  
  15. int main() {
  16. //class Function f;
  17. class Function *f = new class Function;
  18. Function();
  19.  
  20. return 0;
  21. }
Success #stdin #stdout 0s 3028KB
stdin
Standard input is empty
stdout
Function created!
Function called