import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.text.DecimalFormat;
import java.util.Arrays;
import java.util.Scanner;
import java.util.StringTokenizer;

public class Main {
	private StringTokenizer st;
	private BufferedReader bf;
	private int w;
	
	Main() {
		readData();
		

	}	

	private void readData() {
		try {
			bf = new BufferedReader(new InputStreamReader(System.in));
			st = new StringTokenizer(bf.readLine());
			
			
			String s = next();
			for (int i=s.length()-1;i>=0;i--) {
				System.out.print(s.charAt(i));
			}
			System.out.println("");
			
		} catch (Exception e) {
			System.out.println("dacat");
			e.printStackTrace();
		}
	}
	
	private int nextInt() throws IOException {
		return Integer.parseInt(next());
	}
	
	
	private String next() throws IOException {
		try {
		if (st == null || !st.hasMoreTokens())
			st = new StringTokenizer(bf.readLine());
		} catch (Exception e) {
			System.out.println("dacat");
		}
		return st.nextToken();
	}
	
	
	public static void main(String[] args) {
		// TODO Auto-generated method stub
		Main m = new Main();
	}

} import java.io.BufferedReader; BufferedReader java.io import java.io.IOException; IOException java.io import java.io.InputStreamReader; InputStreamReader java.io import java.text.DecimalFormat; DecimalFormat java.text import java.util.Arrays; Arrays java.util import java.util.Scanner; Scanner java.util import java.util.StringTokenizer; StringTokenizer java.util public class Main {
	private StringTokenizer st;
	private BufferedReader bf;
	private int w;
	
	Main() {
		readData();
		

	}	

	private void readData() {
		try {
			bf = new BufferedReader(new InputStreamReader(System.in));
			st = new StringTokenizer(bf.readLine());
			
			
			String s = next();
			for (int i=s.length()-1;i>=0;i--) {
				System.out.print(s.charAt(i));
			}
			System.out.println("");
			
		} catch (Exception e) {
			System.out.println("dacat");
			e.printStackTrace();
		}
	}
	
	private int nextInt() throws IOException {
		return Integer.parseInt(next());
	}
	
	
	private String next() throws IOException {
		try {
		if (st == null || !st.hasMoreTokens())
			st = new StringTokenizer(bf.readLine());
		} catch (Exception e) {
			System.out.println("dacat");
		}
		return st.nextToken();
	}
	
	
	public static void main(String[] args) {
		// TODO Auto-generated method stub
		Main m = new Main();
	}

} Main private StringTokenizer st; st private BufferedReader bf; bf private int w; w Main() {
		readData();
		

	} Main {
		readData();
		

	} readData() readData private void readData() {
		try {
			bf = new BufferedReader(new InputStreamReader(System.in));
			st = new StringTokenizer(bf.readLine());
			
			
			String s = next();
			for (int i=s.length()-1;i>=0;i--) {
				System.out.print(s.charAt(i));
			}
			System.out.println("");
			
		} catch (Exception e) {
			System.out.println("dacat");
			e.printStackTrace();
		}
	} readData {
		try {
			bf = new BufferedReader(new InputStreamReader(System.in));
			st = new StringTokenizer(bf.readLine());
			
			
			String s = next();
			for (int i=s.length()-1;i>=0;i--) {
				System.out.print(s.charAt(i));
			}
			System.out.println("");
			
		} catch (Exception e) {
			System.out.println("dacat");
			e.printStackTrace();
		}
	} try {
			bf = new BufferedReader(new InputStreamReader(System.in));
			st = new StringTokenizer(bf.readLine());
			
			
			String s = next();
			for (int i=s.length()-1;i>=0;i--) {
				System.out.print(s.charAt(i));
			}
			System.out.println("");
			
		} catch (Exception e) {
			System.out.println("dacat");
			e.printStackTrace();
		} catch (Exception e) {
			System.out.println("dacat");
			e.printStackTrace();
		} Exception e {
			System.out.println("dacat");
			e.printStackTrace();
		} System.out.println("dacat") System.out.println System.out System System.out "dacat" e.printStackTrace() e.printStackTrace e {
			bf = new BufferedReader(new InputStreamReader(System.in));
			st = new StringTokenizer(bf.readLine());
			
			
			String s = next();
			for (int i=s.length()-1;i>=0;i--) {
				System.out.print(s.charAt(i));
			}
			System.out.println("");
			
		} bf = new BufferedReader(new InputStreamReader(System.in)) bf new BufferedReader(new InputStreamReader(System.in)) st = new StringTokenizer(bf.readLine()) st new StringTokenizer(bf.readLine()) String s = next(); s next() next for (int i=s.length()-1;i>=0;i--) {
				System.out.print(s.charAt(i));
			} int i=s.length()-1; int i=s.length()-1; i s.length()-1 s.length() s.length s 1 i>=0 i 0 i-- i-- i {
				System.out.print(s.charAt(i));
			} {
				System.out.print(s.charAt(i));
			} System.out.print(s.charAt(i)) System.out.print System.out System System.out s.charAt(i) s.charAt s i System.out.println("") System.out.println System.out System System.out "" private int nextInt() throws IOException {
		return Integer.parseInt(next());
	} nextInt {
		return Integer.parseInt(next());
	} return Integer.parseInt(next()); Integer.parseInt(next()) Integer.parseInt Integer next() next private String next() throws IOException {
		try {
		if (st == null || !st.hasMoreTokens())
			st = new StringTokenizer(bf.readLine());
		} catch (Exception e) {
			System.out.println("dacat");
		}
		return st.nextToken();
	} next {
		try {
		if (st == null || !st.hasMoreTokens())
			st = new StringTokenizer(bf.readLine());
		} catch (Exception e) {
			System.out.println("dacat");
		}
		return st.nextToken();
	} try {
		if (st == null || !st.hasMoreTokens())
			st = new StringTokenizer(bf.readLine());
		} catch (Exception e) {
			System.out.println("dacat");
		} catch (Exception e) {
			System.out.println("dacat");
		} Exception e {
			System.out.println("dacat");
		} System.out.println("dacat") System.out.println System.out System System.out "dacat" {
		if (st == null || !st.hasMoreTokens())
			st = new StringTokenizer(bf.readLine());
		} if (st == null || !st.hasMoreTokens())
			st = new StringTokenizer(bf.readLine()); st == null || !st.hasMoreTokens() st == null st null !st.hasMoreTokens() st.hasMoreTokens() st.hasMoreTokens st st = new StringTokenizer(bf.readLine()) st new StringTokenizer(bf.readLine()) return st.nextToken(); st.nextToken() st.nextToken st public static void main(String[] args) {
		// TODO Auto-generated method stub
		Main m = new Main();
	} main {
		// TODO Auto-generated method stub
		Main m = new Main();
	} Main m = new Main(); m new Main() String[] args args public class Main {
	private StringTokenizer st;
	private BufferedReader bf;
	private int w;
	
	Main() {
		readData();
		

	}	

	private void readData() {
		try {
			bf = new BufferedReader(new InputStreamReader(System.in));
			st = new StringTokenizer(bf.readLine());
			
			
			String s = next();
			for (int i=s.length()-1;i>=0;i--) {
				System.out.print(s.charAt(i));
			}
			System.out.println("");
			
		} catch (Exception e) {
			System.out.println("dacat");
			e.printStackTrace();
		}
	}
	
	private int nextInt() throws IOException {
		return Integer.parseInt(next());
	}
	
	
	private String next() throws IOException {
		try {
		if (st == null || !st.hasMoreTokens())
			st = new StringTokenizer(bf.readLine());
		} catch (Exception e) {
			System.out.println("dacat");
		}
		return st.nextToken();
	}
	
	
	public static void main(String[] args) {
		// TODO Auto-generated method stub
		Main m = new Main();
	}

} public class Main {
	private StringTokenizer st;
	private BufferedReader bf;
	private int w;
	
	Main() {
		readData();
		

	}	

	private void readData() {
		try {
			bf = new BufferedReader(new InputStreamReader(System.in));
			st = new StringTokenizer(bf.readLine());
			
			
			String s = next();
			for (int i=s.length()-1;i>=0;i--) {
				System.out.print(s.charAt(i));
			}
			System.out.println("");
			
		} catch (Exception e) {
			System.out.println("dacat");
			e.printStackTrace();
		}
	}
	
	private int nextInt() throws IOException {
		return Integer.parseInt(next());
	}
	
	
	private String next() throws IOException {
		try {
		if (st == null || !st.hasMoreTokens())
			st = new StringTokenizer(bf.readLine());
		} catch (Exception e) {
			System.out.println("dacat");
		}
		return st.nextToken();
	}
	
	
	public static void main(String[] args) {
		// TODO Auto-generated method stub
		Main m = new Main();
	}

} Main
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.text.DecimalFormat;
import java.util.Arrays;
import java.util.Scanner;
import java.util.StringTokenizer;

public class Main {
	private StringTokenizer st;
	private BufferedReader bf;
	private int w;
	
	Main() {
		readData();
		

	}	

	private void readData() {
		try {
			bf = new BufferedReader(new InputStreamReader(System.in));
			st = new StringTokenizer(bf.readLine());
			
			
			String s = next();
			for (int i=s.length()-1;i>=0;i--) {
				System.out.print(s.charAt(i));
			}
			System.out.println("");
			
		} catch (Exception e) {
			System.out.println("dacat");
			e.printStackTrace();
		}
	}
	
	private int nextInt() throws IOException {
		return Integer.parseInt(next());
	}
	
	
	private String next() throws IOException {
		try {
		if (st == null || !st.hasMoreTokens())
			st = new StringTokenizer(bf.readLine());
		} catch (Exception e) {
			System.out.println("dacat");
		}
		return st.nextToken();
	}
	
	
	public static void main(String[] args) {
		// TODO Auto-generated method stub
		Main m = new Main();
	}

}