求100之间奇偶的和,求输出两个值怎么我才输出1个值求解决
# include <stdio.h>main()
{
int i, j, sum, smm;
sum = 0;
smm = 0;
for(i = 1; i <= 100; i = i + 2 )
sum = sum + i;
printf("100之内奇数的值;%d\n", sum );
for(j = 2; j <= 100; i = i + 2 )
smm = smm + j;
printf("100之内偶数的值;%d\n", smm);
}