温馨提示

P1307 [NOIP2011 普及组] 数字反转

HUTEHE @ 2024-08-05 21:31:52

当输入为0时,要特判,否则Subtask #1TLE


by LIONELMESSIYYDS @ 2024-08-05 21:38:06

不需要啊


#include<bits/stdc++.h>
using namespace std;
int n,s;
int main(){
    cin>>n;
    while(n) s=s*10+n%10,n/=10;
    cout<<s;
    return 0;
}

by HUTEHE @ 2024-08-06 20:44:04

@LIONELMESSIYYDS 咳咳,有些代码要


by LIONELMESSIYYDS @ 2024-08-07 08:07:59

@HETEHE

知道了


by LIONELMESSIYYDS @ 2024-08-07 08:08:28

@HUTEHE


by HUTEHE @ 2024-08-07 08:10:23

@LIONELMESSIYYDS φ(* ̄0 ̄)


by LIONELMESSIYYDS @ 2024-08-07 08:11:43

@HUTEHE

咱俩互关呗


by HUTEHE @ 2024-08-07 08:16:31

@LIONELMESSIYYDS ok


|