read_line/lib.rs
use std::io::stdin;
/// Reads a line of user input from stdin into a String and returns it. Panics on fail.
pub fn read_line() -> String
{
let mut input = String::new();
stdin().read_line(&mut input).expect("Error: unable to read user input");
input
}
/// Prompts the user with the provided &str msg before calling read_line() to get a user input string
pub fn read_line_prompt(msg: &str) -> String
{
println!("{}", msg);
read_line()
}