C語言新手 一問
# include <stdio.h># include <stdlib.h>
int sum(int a1, int b2)
{
int i, temp, total=0;
if(a1<b2){
temp=b2;
b2=a1;
a1=temp;
}
for(i=a1;i<=b2;i++)
total += i;
return total;
}
int main(void)
{
printf("the sum from 1 to 100 is %d\n",sum(1,100));
system("PAUSE");
return 0;
}
-----------------------------------------
temp=b2;
b2=a1;
a1=temp;
我不明這個在記憶體的運行?
請問要怎樣解讀?