第四个点是什么坑?

P1898 缘分计算

```cpp #include <iostream> #include <cmath> #include <sstream> using namespace std; string a,s; int st,n,m,i; string Int_to_String(int n) { ostringstream stream; stream<<n; return stream.str(); } int String_to_Int(string s) { int n=0,c=1; for (int i=m-1;i>=0;i--) { n+=c*(s[i]-'0'); c*=10; } return n; } int main() { cin>>a>>st; for (i=0;i<a.size();i++) s+=Int_to_String(a[i]-'A'+st); m=s.size(); n=1000; while (n>100) { for (i=0;i<m-1;i++) s[i]=char((s[i]-'0'+(s[i+1]-'0'))%10+'0'); --m; if (m<=3) n=String_to_Int(s); } if (s[0]=='0') n=1; else n=0; for (i=n;i<m;i++) cout<<s[i]; cout<<endl; return 0; } ```
by Juventus_Z @ 2017-07-29 09:34:13


楼主你知道是什么坑了吗,我也是第四个点WA
by 浅薄无知 @ 2017-12-16 08:16:23


我也是,求数据
by 龙腾骏 @ 2018-07-23 18:13:13


我也是,求数据+1
by 影のない霜跡 @ 2019-05-25 21:50:04


+2
by critnos @ 2019-08-31 13:51:51


|