int foo(int a, int& b, int c) {
int temp = a;
a = b;
b = c;
c = temp;
return a - b;
}
int main() {
**foo(foo(a, b, c), b, foo(a, b, foo(a, b, c)));**
return 0;
}
首先评估哪个 foo 函数调用,为什么?我发布的代码已简化,因此无需跟踪它。谢谢你
int foo(int a, int& b, int c) {
int temp = a;
a = b;
b = c;
c = temp;
return a - b;
}
int main() {
**foo(foo(a, b, c), b, foo(a, b, foo(a, b, c)));**
return 0;
}
首先评估哪个 foo 函数调用,为什么?我发布的代码已简化,因此无需跟踪它。谢谢你