#include <iostream>
#include <algorithm>
#include <string>

int main() {

   std::string input; // our input string

   std::cout << "Enter a number: ";
   getline (std::cin, input); // get our input


   std::reverse (input.begin(), input.end()); // reverse the input

   std::cout << "Reversed number: " << std::atoi( input.c_str() ) << std::endl;

   return 0;
}
