Recent Posts
printf("ho_tari\n");
sumArray 본문
#include <stdio.h>
int main(void)
{
int nums[10] = {50, 90, 30, 100, 80, 10, 20, 40, 70, 60}; //initialized list
int total = 0;
for (int i = 0; i < 10; ++i)
{
total += nums[i];
}
printf("total: %d\n", total);
return 0;
}
<compile 결과>