method found for reading file line by line