(function reverseStr(str) {
    var splitString = str.split("");  
    var reverseArray = splitString.reverse(); 
    var joinArray = reverseArray.join("");     
    console.log(joinArray);
})(require('fs').readFileSync('/dev/stdin', 'utf8'));