import java.util.Scanner;


public class Main {

	static Scanner sc = new Scanner(System.in);
	static String str;

	public static void main(String[] args) {
		while(read()){
			solve();
		}
	}

	public static Boolean read(){
		if(!sc.hasNext())  return false;

		str = sc.next();
		return true;
	}


	public static void solve(){
		for(int i=str.length()-1; i>=0; i--){
			System.out.print(str.charAt(i));
		}
		System.out.println();
	}

} import java.util.Scanner; Scanner java.util public class Main {

	static Scanner sc = new Scanner(System.in);
	static String str;

	public static void main(String[] args) {
		while(read()){
			solve();
		}
	}

	public static Boolean read(){
		if(!sc.hasNext())  return false;

		str = sc.next();
		return true;
	}


	public static void solve(){
		for(int i=str.length()-1; i>=0; i--){
			System.out.print(str.charAt(i));
		}
		System.out.println();
	}

} Main static Scanner sc = new Scanner(System.in); sc new Scanner(System.in) static String str; str public static void main(String[] args) {
		while(read()){
			solve();
		}
	} main {
		while(read()){
			solve();
		}
	} while(read()){
			solve();
		} read() read {
			solve();
		} solve() solve String[] args args public static Boolean read(){
		if(!sc.hasNext())  return false;

		str = sc.next();
		return true;
	} read {
		if(!sc.hasNext())  return false;

		str = sc.next();
		return true;
	} if(!sc.hasNext())  return false; !sc.hasNext() sc.hasNext() sc.hasNext sc return false; false str = sc.next() str sc.next() sc.next sc return true; true public static void solve(){
		for(int i=str.length()-1; i>=0; i--){
			System.out.print(str.charAt(i));
		}
		System.out.println();
	} solve {
		for(int i=str.length()-1; i>=0; i--){
			System.out.print(str.charAt(i));
		}
		System.out.println();
	} for(int i=str.length()-1; i>=0; i--){
			System.out.print(str.charAt(i));
		} int i=str.length()-1; int i=str.length()-1; i str.length()-1 str.length() str.length str 1 i>=0 i 0 i-- i-- i {
			System.out.print(str.charAt(i));
		} {
			System.out.print(str.charAt(i));
		} System.out.print(str.charAt(i)) System.out.print System.out System System.out str.charAt(i) str.charAt str i System.out.println() System.out.println System.out System System.out public class Main {

	static Scanner sc = new Scanner(System.in);
	static String str;

	public static void main(String[] args) {
		while(read()){
			solve();
		}
	}

	public static Boolean read(){
		if(!sc.hasNext())  return false;

		str = sc.next();
		return true;
	}


	public static void solve(){
		for(int i=str.length()-1; i>=0; i--){
			System.out.print(str.charAt(i));
		}
		System.out.println();
	}

} public class Main {

	static Scanner sc = new Scanner(System.in);
	static String str;

	public static void main(String[] args) {
		while(read()){
			solve();
		}
	}

	public static Boolean read(){
		if(!sc.hasNext())  return false;

		str = sc.next();
		return true;
	}


	public static void solve(){
		for(int i=str.length()-1; i>=0; i--){
			System.out.print(str.charAt(i));
		}
		System.out.println();
	}

} Main
import java.util.Scanner;


public class Main {

	static Scanner sc = new Scanner(System.in);
	static String str;

	public static void main(String[] args) {
		while(read()){
			solve();
		}
	}

	public static Boolean read(){
		if(!sc.hasNext())  return false;

		str = sc.next();
		return true;
	}


	public static void solve(){
		for(int i=str.length()-1; i>=0; i--){
			System.out.print(str.charAt(i));
		}
		System.out.println();
	}

}