#include //C++ example #include using namespace std; void f(int copy, int *p); //function declaration int main() { int i = 10; int j = 20; f(i, &j); cout << "i == " << i << "\n" << "j == " << j << "\n"; return EXIT_SUCCESS; } void f(int copy, int *p) //function definition { ++copy; //has no effect on i ++*p; //adds 1 to j; means *p = *p + 1 }