#include <stdio.h>

int main() {
    int n, soma = 0, produto = 1, i;
    
    scanf("%d", &n);
        
    for (i = 1; i <= n; i++) {
     soma += i;
        produto *= i;
    }

    printf("%d \n", soma);
    printf("%d", produto);
    
    return 0;
}

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: