怎么运用C++引用的知识去求一个数的平方呢?大学计算机问题 帮忙解答
是这意思么? void fun(int &n) { n=n*n; } // ----------------------- int a=10; fun(a); cout << a;