Write a Java method that returns a String representing a file name entered by the user.
Use the
BufferedReader class to obtain input.
```
public static String getFileName() throws IOException
{
BufferedReader stdin = new BufferedReader(new
InputStreamReader(System.in));
System.out.print("Enter the name of the file to open: ");
String fileName = stdin.readLine();
return fileName.trim();
}
```
You might also like to view...
A factor that obstructs with a message between the sender and the recipient is called ________
A) blockage B) feedback C) noise D) breakdown
Recent searches only search the currently displayed location.?
Answer the following statement true (T) or false (F)
The Information Browser provides access to all information not directly related to actual data in the database.
Answer the following statement true (T) or false (F)
The XML _____ signals to the program reading the file that the document is written in XML.
A. ?statement B. ?declaration C. ?index D. ?link