Problem hidden
|This problem was hidden by Editorial Board member probably because it has incorrect language|version or invalid test data, or description of the problem is not clear.|

RGB7070 - Нийлбэр 1

Өгөгдсөн натурал тоо n хүртэлх натурал тоонуудын нийлбэрийг ол.

Давталт ашиглахгүй болно.

Input

Натурал тоо n өгөгдөнө.

Output

Нийлбэр

Example

Input:
10

Output:
55

Нэмсэн:Bataa
Огноо:2013-01-06
Хугацааны хязгаарлалт:1s
Эх кодын хэмжээний хязгаарлалт:50000B
Memory limit:1536MB
Cluster: Cube (Intel G860)
Програмчлалын хэлүүд:ADA95 ASM32 BASH BF C NCSHARP CSHARP C++ 4.3.2 CPP C99 CLPS LISP sbcl LISP clisp D ERL FORTRAN HASK ICON ICK JAVA JS-RHINO JULIA LUA NEM NICE OCAML PAS-GPC PAS-FPC PERL PHP PIKE PRLG-swi PYTHON PYPY3 PYTHON3 RUBY SCALA SCM guile ST TCL WHITESPACE

hide comments
2021-12-11 13:04:27
a = int(input())
s = 0
for i in range(1,a+1):
s +=i
print(s)
ez
2021-11-18 03:51:09
9
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
19
123456789
12345678
1234567
123456
12345
1234
123
12
1dont coy

Last edit: 2021-11-18 03:51:33
2021-10-11 12:30:38
#include <iostream>
using namespace std;

int main() {
int a;
cin>>a;
cout<<a*(a+1)/2;
return 0;
}

2021-05-27 18:09:47
#include <iostream>
using namespace std;

int main() {


int niilber,a,b,c,d,n,i;

cin >>n;
niilber = 0 ;
for (a =1 ; a<=n ; a ++ )
niilber +=a;


cout <<niilber;




return 0;
}
2021-01-17 10:56:08
;-;
2021-01-12 10:14:07
#include<bits/stdc++.h>
using namespace std;
int main()
{
int a,n,c;
cin>>a>>n;
c=a*n;
cout<<c;
return 0;
}
2020-08-14 03:55:47
sdsdsdsdsdsdsds dfdfdfdfdfdf
2020-05-12 08:32:12
n * (n + 1) / 2
2019-12-29 04:31:14
bodooroi
2019-11-21 04:55:11
#include <iostream>
using namespace std;
int main(){
int n, s;
cin >> n;
s = n * (n + 1) / 2;
cout<< s <<endl;
return 0;
}
© Spoj.com. All Rights Reserved. Spoj uses Sphere Engine™ © by Sphere Research Labs.