#include <iostream> using namespace std; #include<string> #include<algorithm>//用reverse的头文件 string a; int main() { int b; cin>>a; reverse(a.begin(),a.end());//直接翻了,暴力且省事 cout<<a; } // 64 位输出请用 printf("%lld") //#牛客春招刷题训练营#https://www.nowcoder.com/discuss/727521113110073344