求助!为什么无法通过/(ㄒoㄒ)/~~!测试样例代入是对的呀

P1307 [NOIP2011 普及组] 数字反转

m3o7o2n1 @ 2024-02-06 19:16:15

#include <stdio.h>
int main() {
    int y,sum,n;
    scanf("%d",&n);
    while(n!=0){
        y=n%10;
        sum=sum*10+y;
        n=n/10;
    }
    printf("%d",sum);
    return 0;
}

by m3o7o2n1 @ 2024-02-29 17:46:33

@DFs_YYDS (;´д`)ゞ


上一页 |