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

//public class Problem0006_ReverseSequence {
public class Main {
	public static void main(String[] args) {
		try {
			BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
			String line;
			
			while((line = reader.readLine()) != null) {
				char[] sequence = line.toCharArray();
				if(sequence.length == 0) {
					break;
				}
				for(int i = sequence.length -1; i > -1; i--) {
					System.out.print(sequence[i]);
				}
				System.out.println();
			}
		} catch(Exception e) {
			e.printStackTrace();
		}
	}
} import java.io.BufferedReader; BufferedReader java.io import java.io.InputStreamReader; InputStreamReader java.io public class Main {
	public static void main(String[] args) {
		try {
			BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
			String line;
			
			while((line = reader.readLine()) != null) {
				char[] sequence = line.toCharArray();
				if(sequence.length == 0) {
					break;
				}
				for(int i = sequence.length -1; i > -1; i--) {
					System.out.print(sequence[i]);
				}
				System.out.println();
			}
		} catch(Exception e) {
			e.printStackTrace();
		}
	}
} Main public static void main(String[] args) {
		try {
			BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
			String line;
			
			while((line = reader.readLine()) != null) {
				char[] sequence = line.toCharArray();
				if(sequence.length == 0) {
					break;
				}
				for(int i = sequence.length -1; i > -1; i--) {
					System.out.print(sequence[i]);
				}
				System.out.println();
			}
		} catch(Exception e) {
			e.printStackTrace();
		}
	} main {
		try {
			BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
			String line;
			
			while((line = reader.readLine()) != null) {
				char[] sequence = line.toCharArray();
				if(sequence.length == 0) {
					break;
				}
				for(int i = sequence.length -1; i > -1; i--) {
					System.out.print(sequence[i]);
				}
				System.out.println();
			}
		} catch(Exception e) {
			e.printStackTrace();
		}
	} try {
			BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
			String line;
			
			while((line = reader.readLine()) != null) {
				char[] sequence = line.toCharArray();
				if(sequence.length == 0) {
					break;
				}
				for(int i = sequence.length -1; i > -1; i--) {
					System.out.print(sequence[i]);
				}
				System.out.println();
			}
		} catch(Exception e) {
			e.printStackTrace();
		} catch(Exception e) {
			e.printStackTrace();
		} Exception e {
			e.printStackTrace();
		} e.printStackTrace() e.printStackTrace e {
			BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
			String line;
			
			while((line = reader.readLine()) != null) {
				char[] sequence = line.toCharArray();
				if(sequence.length == 0) {
					break;
				}
				for(int i = sequence.length -1; i > -1; i--) {
					System.out.print(sequence[i]);
				}
				System.out.println();
			}
		} BufferedReader reader = new BufferedReader(new InputStreamReader(System.in)); reader new BufferedReader(new InputStreamReader(System.in)) String line; line while((line = reader.readLine()) != null) {
				char[] sequence = line.toCharArray();
				if(sequence.length == 0) {
					break;
				}
				for(int i = sequence.length -1; i > -1; i--) {
					System.out.print(sequence[i]);
				}
				System.out.println();
			} (line = reader.readLine()) != null (line = reader.readLine()) line reader.readLine() reader.readLine reader null {
				char[] sequence = line.toCharArray();
				if(sequence.length == 0) {
					break;
				}
				for(int i = sequence.length -1; i > -1; i--) {
					System.out.print(sequence[i]);
				}
				System.out.println();
			} char[] sequence = line.toCharArray(); sequence line.toCharArray() line.toCharArray line if(sequence.length == 0) {
					break;
				} sequence.length == 0 sequence.length sequence sequence.length 0 {
					break;
				} break; for(int i = sequence.length -1; i > -1; i--) {
					System.out.print(sequence[i]);
				} int i = sequence.length -1; int i = sequence.length -1; i sequence.length -1 sequence.length sequence sequence.length 1 i > -1 i -1 1 i-- i-- i {
					System.out.print(sequence[i]);
				} {
					System.out.print(sequence[i]);
				} System.out.print(sequence[i]) System.out.print System.out System System.out sequence[i] sequence i System.out.println() System.out.println System.out System System.out String[] args args public class Main {
	public static void main(String[] args) {
		try {
			BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
			String line;
			
			while((line = reader.readLine()) != null) {
				char[] sequence = line.toCharArray();
				if(sequence.length == 0) {
					break;
				}
				for(int i = sequence.length -1; i > -1; i--) {
					System.out.print(sequence[i]);
				}
				System.out.println();
			}
		} catch(Exception e) {
			e.printStackTrace();
		}
	}
} public class Main {
	public static void main(String[] args) {
		try {
			BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
			String line;
			
			while((line = reader.readLine()) != null) {
				char[] sequence = line.toCharArray();
				if(sequence.length == 0) {
					break;
				}
				for(int i = sequence.length -1; i > -1; i--) {
					System.out.print(sequence[i]);
				}
				System.out.println();
			}
		} catch(Exception e) {
			e.printStackTrace();
		}
	}
} Main
import java.io.BufferedReader;
import java.io.InputStreamReader;

//public class Problem0006_ReverseSequence {
public class Main {
	public static void main(String[] args) {
		try {
			BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));
			String line;
			
			while((line = reader.readLine()) != null) {
				char[] sequence = line.toCharArray();
				if(sequence.length == 0) {
					break;
				}
				for(int i = sequence.length -1; i > -1; i--) {
					System.out.print(sequence[i]);
				}
				System.out.println();
			}
		} catch(Exception e) {
			e.printStackTrace();
		}
	}
}