Edited code so that Serial can be read line-by-line