#include<iostream>
#include<string>
#include<string.h>
using namespace std;
string change(string a, int n)
{
int i=0;
int j=n-1;
char tmp;
for(i,j;i<n/2;i++,j--)
{
tmp = a[i];
a[i] = a[j];
a[j] = tmp;
}
cout<<a<<endl;
string b = a;
return b;
}
int main(int argc, char** argv)
{
string a,s;
int n;
cout<<"请输入你的字符串:";
getline(cin,a);
n = a.size();
cout<<"长度:"<<n<<endl;
s = change(a,n);
cout<<s<<endl;
}