Mary_mzxx @ 2021-12-06 20:15:23
代码
代码
为什么只有90
#include<iostream>
#include<cstring>
using namespace std;
char s[14],c;
int main(){
cin>>s;
int h=0,k=0;
for(int i=0;i<11;i++){
if(s[i]!='-'){
k++;
h+=k*(s[i]-'0');
}
}
h%=11;
if(h==10){
c='X';
}
else{
c=h+'0';
}
if(c==s[12]){
cout<<"Right";
}
else{
s[12]=c;
cout<<s;
}
return 0;
}
徒儿前来求助
谢谢
谢谢
谢谢
by xixike @ 2021-12-06 20:24:25
@Mary20110401 你这个代码不是能过吗?
by Mary_mzxx @ 2021-12-06 20:29:22
过不了
by farmer_snack @ 2021-12-08 19:20:26
@Mary20110401 选自动识别语言
by Mary_mzxx @ 2021-12-12 11:14:26
哦
过了