求条
查看原帖
求条
1213919
bwtx_Minemain0943楼主2025/1/20 16:30
#include <stdio.h>

int main(){
    char str[7],str1[7];
    int cnt=1,cnt1=1;
    for(int i = 1; i<=6; i++){
        scanf("%c",&str[i]);
        cnt*=str[i]-64;
    }for(int i = 1; i<=6; i++){
        scanf("%c",&str1[i]);
        cnt1*=str1[i]-64;
    }
    if(cnt%47==cnt1%47) puts("GO");
    else puts("STAY");
}

'\0'的ASCII码不是0吗for到6为什么会有问题

2025/1/20 16:30
加载中...