Cod sursa(job #635900)

Utilizator a_h1926Heidelbacher Andrei a_h1926 Data 19 noiembrie 2011 15:30:39
Problema Dirichlet Scor 0
Compilator cpp Status done
Runda .com 2011 Marime 0.24 kb
#include <cstdio>

using namespace std;

long long N;

int main()
{
    freopen ("dirichlet.in", "r", stdin);
    freopen ("dirichlet.out", "w", stdout);
    scanf ("%lld", &N);
    printf ("%lld\n", (N*(N+1))/2-1);
    return 0;
}