A good answer might be:

Click!

Closing Files

Here is the file closing method. It is possible (though rare) for closing a file to fail. Here, each attempt is given its own try{} block so the error messages can be specific.

class CopyMaker
{
   String sourceName, destName;
   BufferedReader source;
   BufferedWriter dest;
   String line;

   private boolean closeFiles()  //return true if files close, else false
   {
     boolean retVal=true;

     // close the source
     try
     {      
       source.();
     }
     catch ( IOException iox )
     {
       System.out.println("Problem closing " +);
       retVal = ;
     }

     // close the destination
     try
     {      
       dest.();
     }
     catch ( IOException iox )
     {
       System.out.println("Problem closing " +);
       retVal = ;
     }
     return ;
   }
}

QUESTION 11:

Why is it important that the first catch{} block does not end with return false?

Click Here after you have answered the question