use std::io; fn main() { println!("{}", reversed(read_line())); } fn read_line() -> String { let mut line = String::new(); io::stdin().read_line(&mut line) .expect("Failed to read line"); return line } fn reversed(str: String) -> String { return str.chars().rev().collect::(); }