Run ID | Author | Problem | Lang | Verdict | Time | Memory | Code Length | Submit Time |
---|---|---|---|---|---|---|---|---|
37317 | ☩Deutschland☩ | 求1+2+3+... | C++ | Accepted | 0 MS | 244 KB | 122 | 2024-01-20 10:09:10 |
#include<bits/stdc++.h> using namespace std; int main(){ int n,s; cin>>n; s=(1+n)*n/2; cout<<s; return 0; }