use raw strings for regex pattern, add newline
add argument parsing, use variable for input file
remove dead code
reorder functions

- only create regex pattern if there is a valid file to read
throw exception when the file isn't found