fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int x(int a) {return a + 3;}
  5. int x(double a) {return (int)a;}
  6.  
  7. int main() {
  8. // your code goes here
  9. std::cout << "Hello, World!\n" << "x(3):" << x(3) << "\nx(3.0):" << x(3.0);
  10. return 0;
  11. }
Success #stdin #stdout 0s 3468KB
stdin
Standard input is empty
stdout
Hello, World!
x(3):6
x(3.0):3