请问如下代码为什么编译不过?
请问如下代码为什么编译不过?
去掉Exp(int& n)中的&就可以编译通过。
#include <stdio.h>
int Exp(int& n)
{
int count = 0;
// something else
return count;
}
int main()
{
int n,k,count1,count2,count3;
while (EOF != scanf("%d%d",&n,&k))
{
count1 = Exp(n);
count2 = Exp(k);
count3 = Exp(n-k);
}
return 0;
}