Clean up IO system

Clean up and refactor code
Support lines with comments
Support skipping blank lines
Rename keyword arguments
Automatically handle multiple types of newlines
Increase number of IO tests and classify data sets
Fix handling of Windows newlines