Skip to content

Instantly share code, notes, and snippets.

@tiger1710
Last active February 19, 2019 11:27
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tiger1710/dacc199758edcc951180da5e6730a39e to your computer and use it in GitHub Desktop.
Save tiger1710/dacc199758edcc951180da5e6730a39e to your computer and use it in GitHub Desktop.
#include <iostream>
using namespace std;
int f(int a) {
a = 0;
return a;
}
int foo1(int b) {
return f(b) + 1;
}
int foo2(int c) {
return f(c);
}
int main(void) {
cout << foo1(10) << '\n';
cout << foo2(10) << '\n';
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment