Question: Write a method that will open a connection to a file (inputFile.txt) , read in the first line from the file and return the whole
Write a method that will open a connection to a file ("inputFile.txt") , read in the first line from the file and return the whole line from the method (as a String). Make sure you handle exceptions as needed. You can assume any libraries needed are already included.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
