Changed up parsing to look for commas instead of newline characters along with resetting the value in getWord for the second loop.