diff --git a/src/main.rs b/src/main.rs index dac07c4..4ac8bc8 100644 --- a/src/main.rs +++ b/src/main.rs @@ -18,5 +18,10 @@ fn main() { bytes_read = io::stdin() .read_line(&mut user_input) .expect("error reading user input"); + + if bytes_read == 0 { + println!(); + exit(); + } } }