linerqun10086 @ 2022-03-25 20:26:44
#include<bits/stdc++.h>
using namespace std;
char a[15],c;
int m[15],n;
int main(){
for(int i=1;i<=12;i++){
cin>>a[i];
}
cin>>c;
for(int i=1;i<=9;i++){
int b=i;
if(i>=6){
b=i+2;
}
else if(i>=2){
b=i+1;
}
m[i]=(int)a[b];
}
for(int i=1;i<=9;i++){
n+=i*m[i];
}
if(n%11==c){
cout<<"Right";
}
else if(n%11!=c){
for(int i=1;i<=12;i++){
cout<<a[i];
}
cout<<n%11;
}
return 0;
}
by zhangbg @ 2022-03-31 00:03:16