benben0218 @ 2022-07-24 15:32:16
#include <cstdio>
using namespace std;
int main() {
char a, b, c, d, e, f, g, h, i, j;
int check;
scanf("%c-%c%c%c-%c%c%c%c%c-%c",&a,&b,&c,&d,&e,&f,&g,&h,&i,&j);
check = (a-'0')*1 + (b-'0')*2 + (c-'0')*3 + (d-'0')*4 + (e-'0')*5+ (f-'0')*6 + (g-'0')*7 + (h-'0')*8 + (i-'0')*9;
check%=11;
if(j=='x'&&check==10||check==j-'0')
printf("Right\n");
else
printf("%c-%c%c%c-%c%c%c%c%c-%c",a,b,c,d,e,f,g,h,i,check==10?'x':check+'0');
return 0;
}
请大佬多多指教 谢谢
by NOI_and_IOI_ak_VVK @ 2022-07-24 15:33:09
X要大写
by NOI_and_IOI_ak_VVK @ 2022-07-24 15:33:43
https://www.luogu.com.cn/record/80966272
by benben0218 @ 2022-07-24 15:35:18
谢谢 以后多注意一下细节