Skip to main content

read_input

Function read_input 

Source
pub fn read_input(
    file: Option<&Path>,
    fallback: impl Read,
) -> Result<Vec<String>>
Expand description

Read all lines from either a file path or the provided reader (typically stdin). Trailing \n/\r\n is stripped per line. A trailing empty line (from a terminating newline) is dropped.