import java.util.*;

public class Main {
    static Scanner sc = new Scanner(System.in);
    static String input;
    public static void main(String[] args) {
        while(read()){
            slove();
        }
    }
    static  boolean read(){
        if(!sc.hasNext())return false;
        input = sc.nextLine();
        return true;
    }
    static void slove(){
        String res = new StringBuffer(input).reverse().toString();
        System.out.println(res);
        //res = new StringBuffer("1234gtt").reverse().toString();
        //System.out.println(res);
    }
} import java.util.*; util.* java public class Main {
    static Scanner sc = new Scanner(System.in);
    static String input;
    public static void main(String[] args) {
        while(read()){
            slove();
        }
    }
    static  boolean read(){
        if(!sc.hasNext())return false;
        input = sc.nextLine();
        return true;
    }
    static void slove(){
        String res = new StringBuffer(input).reverse().toString();
        System.out.println(res);
        //res = new StringBuffer("1234gtt").reverse().toString();
        //System.out.println(res);
    }
} Main static Scanner sc = new Scanner(System.in); sc new Scanner(System.in) static String input; input public static void main(String[] args) {
        while(read()){
            slove();
        }
    } main {
        while(read()){
            slove();
        }
    } while(read()){
            slove();
        } read() read {
            slove();
        } slove() slove String[] args args static  boolean read(){
        if(!sc.hasNext())return false;
        input = sc.nextLine();
        return true;
    } read {
        if(!sc.hasNext())return false;
        input = sc.nextLine();
        return true;
    } if(!sc.hasNext())return false; !sc.hasNext() sc.hasNext() sc.hasNext sc return false; false input = sc.nextLine() input sc.nextLine() sc.nextLine sc return true; true static void slove(){
        String res = new StringBuffer(input).reverse().toString();
        System.out.println(res);
        //res = new StringBuffer("1234gtt").reverse().toString();
        //System.out.println(res);
    } slove {
        String res = new StringBuffer(input).reverse().toString();
        System.out.println(res);
        //res = new StringBuffer("1234gtt").reverse().toString();
        //System.out.println(res);
    } String res = new StringBuffer(input).reverse().toString(); res new StringBuffer(input).reverse().toString() new StringBuffer(input).reverse().toString new StringBuffer(input).reverse() new StringBuffer(input).reverse new StringBuffer(input) System.out.println(res) System.out.println System.out System System.out res public class Main {
    static Scanner sc = new Scanner(System.in);
    static String input;
    public static void main(String[] args) {
        while(read()){
            slove();
        }
    }
    static  boolean read(){
        if(!sc.hasNext())return false;
        input = sc.nextLine();
        return true;
    }
    static void slove(){
        String res = new StringBuffer(input).reverse().toString();
        System.out.println(res);
        //res = new StringBuffer("1234gtt").reverse().toString();
        //System.out.println(res);
    }
} public class Main {
    static Scanner sc = new Scanner(System.in);
    static String input;
    public static void main(String[] args) {
        while(read()){
            slove();
        }
    }
    static  boolean read(){
        if(!sc.hasNext())return false;
        input = sc.nextLine();
        return true;
    }
    static void slove(){
        String res = new StringBuffer(input).reverse().toString();
        System.out.println(res);
        //res = new StringBuffer("1234gtt").reverse().toString();
        //System.out.println(res);
    }
} Main
import java.util.*;

public class Main {
    static Scanner sc = new Scanner(System.in);
    static String input;
    public static void main(String[] args) {
        while(read()){
            slove();
        }
    }
    static  boolean read(){
        if(!sc.hasNext())return false;
        input = sc.nextLine();
        return true;
    }
    static void slove(){
        String res = new StringBuffer(input).reverse().toString();
        System.out.println(res);
        //res = new StringBuffer("1234gtt").reverse().toString();
        //System.out.println(res);
    }
}