九十分,第一个测试点过不了,求助大佬,蟹蟹丫

P1200 [USACO1.1] 你的飞碟在这儿 Your Ride Is Here

希望更丰富的展现?使用Markdown.
by 天南月 @ 2019-07-19 20:24:56


```cpp #include<iostream> #include<cstdio> #include<cstring> using namespace std; char a[6],b[6]; int main() { int la,lb,i,ans1=1,ans2=1; int x[6]={0},y[6]={0}; gets(a); la=strlen(a); gets(b); lb=strlen(b); for(i=0;i<la;i++) { x[i]=a[i]-64; ans1=x[i]; } for(i=0;i<lb;i++) { y[i]=b[i]-64; ans2=y[i]; } ans1%=47; ans2%=47; if(ans1==ans2) cout<<"GO"; else cout<<"STAY"; return 0; } ``` 希望更丰富的展现?使用Markdown.
by Vector_ @ 2019-07-19 20:36:08


请不要使用Markdown来强调头文件的重要性。
by Smile_Cindy @ 2019-07-19 20:37:41


@[Vector_](/space/show?uid=126763) 不应该是“ans1*=x【i】” “ans2*=y【i】”嘛
by 小小小小小迪 @ 2019-07-19 21:48:17


@[天南月](/space/show?uid=179927) ???
by 小小小小小迪 @ 2019-07-19 21:48:35


@[Alpha](/space/show?uid=87058) 蟹蟹吖
by 小小小小小迪 @ 2019-07-19 21:49:14


@[小小小小小迪](/space/show?uid=209500) ~~我只是把你的代码用Markdown排了下版 像我这种蒟蒻是查不出错的~~
by Vector_ @ 2019-07-20 20:49:51


|