import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;


public class Main {
	private	static	BufferedReader br = null;

	static {
		br = new BufferedReader(new InputStreamReader(System.in));
	}

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		// TODO Auto-generated method stub
		String	str = null;

		while((str = parseStr()) != null) {
			str = reverse(str);
			System.out.println(str);
		}
	}

	private static String parseStr() {
		String	str = null;

		try {
			String line = br.readLine();
			if (line != null) {
				if (!line.isEmpty()) {
					str = line;
				}
			}
		}
		catch (NumberFormatException e) {}
		catch (IOException e) {}

		return str;
	}

	private static String reverse(String str) {
		char[]	buff = str.toCharArray();
		int		nLen = str.length();
		char	c    = 0;

		for(int n1 = 0, n2 = nLen - 1; n1 < n2; n1++, n2--) {
			c        = buff[n1];
			buff[n1] = buff[n2];
			buff[n2] = c;
		}

		
		return String.valueOf(buff);
	}
} import java.io.BufferedReader; BufferedReader java.io import java.io.IOException; IOException java.io import java.io.InputStreamReader; InputStreamReader java.io public class Main {
	private	static	BufferedReader br = null;

	static {
		br = new BufferedReader(new InputStreamReader(System.in));
	}

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		// TODO Auto-generated method stub
		String	str = null;

		while((str = parseStr()) != null) {
			str = reverse(str);
			System.out.println(str);
		}
	}

	private static String parseStr() {
		String	str = null;

		try {
			String line = br.readLine();
			if (line != null) {
				if (!line.isEmpty()) {
					str = line;
				}
			}
		}
		catch (NumberFormatException e) {}
		catch (IOException e) {}

		return str;
	}

	private static String reverse(String str) {
		char[]	buff = str.toCharArray();
		int		nLen = str.length();
		char	c    = 0;

		for(int n1 = 0, n2 = nLen - 1; n1 < n2; n1++, n2--) {
			c        = buff[n1];
			buff[n1] = buff[n2];
			buff[n2] = c;
		}

		
		return String.valueOf(buff);
	}
} Main private	static	BufferedReader br = null; br null /**
	 * @param args
	 */
	public static void main(String[] args) {
		// TODO Auto-generated method stub
		String	str = null;

		while((str = parseStr()) != null) {
			str = reverse(str);
			System.out.println(str);
		}
	} main {
		// TODO Auto-generated method stub
		String	str = null;

		while((str = parseStr()) != null) {
			str = reverse(str);
			System.out.println(str);
		}
	} String	str = null; str null while((str = parseStr()) != null) {
			str = reverse(str);
			System.out.println(str);
		} (str = parseStr()) != null (str = parseStr()) str parseStr() parseStr null {
			str = reverse(str);
			System.out.println(str);
		} str = reverse(str) str reverse(str) reverse str System.out.println(str) System.out.println System.out System System.out str String[] args args private static String parseStr() {
		String	str = null;

		try {
			String line = br.readLine();
			if (line != null) {
				if (!line.isEmpty()) {
					str = line;
				}
			}
		}
		catch (NumberFormatException e) {}
		catch (IOException e) {}

		return str;
	} parseStr {
		String	str = null;

		try {
			String line = br.readLine();
			if (line != null) {
				if (!line.isEmpty()) {
					str = line;
				}
			}
		}
		catch (NumberFormatException e) {}
		catch (IOException e) {}

		return str;
	} String	str = null; str null try {
			String line = br.readLine();
			if (line != null) {
				if (!line.isEmpty()) {
					str = line;
				}
			}
		}
		catch (NumberFormatException e) {}
		catch (IOException e) {} catch (NumberFormatException e) {} NumberFormatException e {} catch (IOException e) {} IOException e {} {
			String line = br.readLine();
			if (line != null) {
				if (!line.isEmpty()) {
					str = line;
				}
			}
		} String line = br.readLine(); line br.readLine() br.readLine br if (line != null) {
				if (!line.isEmpty()) {
					str = line;
				}
			} line != null line null {
				if (!line.isEmpty()) {
					str = line;
				}
			} if (!line.isEmpty()) {
					str = line;
				} !line.isEmpty() line.isEmpty() line.isEmpty line {
					str = line;
				} str = line str line return str; str private static String reverse(String str) {
		char[]	buff = str.toCharArray();
		int		nLen = str.length();
		char	c    = 0;

		for(int n1 = 0, n2 = nLen - 1; n1 < n2; n1++, n2--) {
			c        = buff[n1];
			buff[n1] = buff[n2];
			buff[n2] = c;
		}

		
		return String.valueOf(buff);
	} reverse {
		char[]	buff = str.toCharArray();
		int		nLen = str.length();
		char	c    = 0;

		for(int n1 = 0, n2 = nLen - 1; n1 < n2; n1++, n2--) {
			c        = buff[n1];
			buff[n1] = buff[n2];
			buff[n2] = c;
		}

		
		return String.valueOf(buff);
	} char[]	buff = str.toCharArray(); buff str.toCharArray() str.toCharArray str int		nLen = str.length(); nLen str.length() str.length str char	c    = 0; c 0 for(int n1 = 0, n2 = nLen - 1; n1 < n2; n1++, n2--) {
			c        = buff[n1];
			buff[n1] = buff[n2];
			buff[n2] = c;
		} int n1 = 0, n2 = nLen - 1; int n1 = 0 n1 0 n2 = nLen - 1; n2 nLen - 1 nLen 1 n1 < n2 n1 n2 n1++, n2-- n1++ n1 n2-- n2 {
			c        = buff[n1];
			buff[n1] = buff[n2];
			buff[n2] = c;
		} {
			c        = buff[n1];
			buff[n1] = buff[n2];
			buff[n2] = c;
		} c        = buff[n1] c buff[n1] buff n1 buff[n1] = buff[n2] buff[n1] buff n1 buff[n2] buff n2 buff[n2] = c buff[n2] buff n2 c return String.valueOf(buff); String.valueOf(buff) String.valueOf String buff String str str public class Main {
	private	static	BufferedReader br = null;

	static {
		br = new BufferedReader(new InputStreamReader(System.in));
	}

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		// TODO Auto-generated method stub
		String	str = null;

		while((str = parseStr()) != null) {
			str = reverse(str);
			System.out.println(str);
		}
	}

	private static String parseStr() {
		String	str = null;

		try {
			String line = br.readLine();
			if (line != null) {
				if (!line.isEmpty()) {
					str = line;
				}
			}
		}
		catch (NumberFormatException e) {}
		catch (IOException e) {}

		return str;
	}

	private static String reverse(String str) {
		char[]	buff = str.toCharArray();
		int		nLen = str.length();
		char	c    = 0;

		for(int n1 = 0, n2 = nLen - 1; n1 < n2; n1++, n2--) {
			c        = buff[n1];
			buff[n1] = buff[n2];
			buff[n2] = c;
		}

		
		return String.valueOf(buff);
	}
} public class Main {
	private	static	BufferedReader br = null;

	static {
		br = new BufferedReader(new InputStreamReader(System.in));
	}

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		// TODO Auto-generated method stub
		String	str = null;

		while((str = parseStr()) != null) {
			str = reverse(str);
			System.out.println(str);
		}
	}

	private static String parseStr() {
		String	str = null;

		try {
			String line = br.readLine();
			if (line != null) {
				if (!line.isEmpty()) {
					str = line;
				}
			}
		}
		catch (NumberFormatException e) {}
		catch (IOException e) {}

		return str;
	}

	private static String reverse(String str) {
		char[]	buff = str.toCharArray();
		int		nLen = str.length();
		char	c    = 0;

		for(int n1 = 0, n2 = nLen - 1; n1 < n2; n1++, n2--) {
			c        = buff[n1];
			buff[n1] = buff[n2];
			buff[n2] = c;
		}

		
		return String.valueOf(buff);
	}
} Main
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;


public class Main {
	private	static	BufferedReader br = null;

	static {
		br = new BufferedReader(new InputStreamReader(System.in));
	}

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		// TODO Auto-generated method stub
		String	str = null;

		while((str = parseStr()) != null) {
			str = reverse(str);
			System.out.println(str);
		}
	}

	private static String parseStr() {
		String	str = null;

		try {
			String line = br.readLine();
			if (line != null) {
				if (!line.isEmpty()) {
					str = line;
				}
			}
		}
		catch (NumberFormatException e) {}
		catch (IOException e) {}

		return str;
	}

	private static String reverse(String str) {
		char[]	buff = str.toCharArray();
		int		nLen = str.length();
		char	c    = 0;

		for(int n1 = 0, n2 = nLen - 1; n1 < n2; n1++, n2--) {
			c        = buff[n1];
			buff[n1] = buff[n2];
			buff[n2] = c;
		}

		
		return String.valueOf(buff);
	}
}