use std::io::{self, Write};
fn main() -> anyhow::Result<()> {
ctrlc::set_handler(move || {
println!();
std::process::exit(0);
})?;
loop {
print!("[zoro]> ");
io::stdout().flush()?;
let mut input = String::new();
if io::stdin().read_line(&mut input)? == 0 {
println!();
break;
}
println!("You typed {}", input.trim());
}
Ok(())
}