Run ID 作者 问题 语言 测评结果 分数 时间 内存 代码长度 提交时间
335148 李俞家骅 【C2-2】编程求解1+2+3+...+n C++ 通过 100 3 MS 248 KB 164 2025-07-22 09:12:44

Tests(4/4):


#include<bits/stdc++.h> using namespace std; int main(){ int n,i=1,x=0; cin>>n; while(i<=n){ x=x+i; i++; }cout<<x<<endl; return 0; }


测评信息: