added source code that reads lines in file