#include <stdio.h>

int sum(int n){
	int c = 0;
	int d = 0;
	while(n -- > 1)
		c ++;
		d = c + d;
		return c,d;
}

int main(void) {
	int a,b;
    a = 10;
    b = sum(a);
    printf("1から%dまでの和は%d", a,b );
	return 0;
}
