Changed answer reading to getline
Cleaned up code