Run ID 作者 问题 语言 测评结果 分数 时间 内存 代码长度 提交时间
127571 陈明朗 求Sn的值 C++ 通过 100 0 MS 244 KB 194 2024-01-25 09:32:45

Tests(5/5):


#include <bits/stdc++.h> using namespace std; int main() { int a,n,b,i,sum=0,j; cin>>a>>n; b=a; sum+=a; for(i=1;i<=n-1;i++){ a=a*10+b; sum+=a; } cout<<sum; return 0; }


测评信息: