pghsteelers
Technical User
I understand the general explanation of the expression variable++ or ++variable as in when the variable is incremented during the carring out of an expression. However, can someone clarify how it occurs when being passed as a parameter in a function such as:
y = functionName(var1, ++var2);
as apposed to
y = functionName(var1, var2++);
...
...
...
int functionName(int var1, int var2)
{
sum = var1 + var2;
return sum;
}
Thanks in advance
y = functionName(var1, ++var2);
as apposed to
y = functionName(var1, var2++);
...
...
...
int functionName(int var1, int var2)
{
sum = var1 + var2;
return sum;
}
Thanks in advance