int sum(int x,int y)
{
sum=x+y;
return(sum);
}
You cannot use the function name as a variable, it is a function of type int _cdecl sum
This will work...
int sum(int x,int y)
{
int ret;
ret = x+y;
return ret;
}
As a rule you should not create variables execpt when you need them so...
You can do this...
int sum(int x,int y)
{
return x+y;
}