DSA/algorithms/CPlusPlus/Strings/string-reverse.cpp

13 lines
167 B
C++

#include <iostream>
#include<string>
#include<algorithm>
using namespace std;
int main() {
string s;
cin>>s;
reverse(s.begin(),s.end());
cout<<s;
return 0;
}