Loading [Contrib]/a11y/accessibility-menu.js
Toggle navigation
Sky Online Judge
Problems
Challenges
Contest
Tools
Coder
Scoreboard
Code
Dev Message
Discuss
Make-A-Wish
LOGIN
上傳編號
191513
上傳時間
2024-01-06 15:10:48
題目
[練習題]西格馬嗯
使用者
anonymous
總得分
100,
Accepted
AC
in 540 ms
#
State
Runtime
Memory
0
Accepted
AC
0
389120
1
Accepted
AC
0
385024
2
Accepted
AC
0
368640
3
Accepted
AC
540
385024
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
/******************************************************************************
Online C++ Compiler.
Code, Compile, Run and Debug C++ program online.
Write your code in this editor and press "Run" button to compile and execute it.
*******************************************************************************/
#include
<iostream>
using
namespace
std
;
int
main
(
)
{
long
long
int
n
,
a
;
cin
>>
n
;
a
=
0
;
for
(
int
i
=
1
;
i
<=
n
;
i
++
)
{
a
=
a
+
i
;
}
cout
<<
a
<<
endl
;
}
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX