NOJ/20/main.c
Saturneric 52668c4122 Add.
2020-09-01 00:46:43 +08:00

16 lines
304 B
C

#include <stdio.h>
int main(void){
int number, i;
scanf("%d",&number);
printf("%d*%d*%d=%lu=",number,number,number,(unsigned long)number*number*number);
int k = number * number - number + 1;
for(i = 0; i < number; i++,k += 2){
if(i) printf("+");
printf("%d",k);
}
printf("\n");
return 0;
}