InterviewSolution
Saved Bookmarks
| 1. |
If a file that needs to be opened is not found in the target location then _____________(a) Exception will be produced(b) Exceptions are not produced(c) Exception might get produced because of syntax(d) Exceptions are not produced because of logicI got this question during an interview.My question is from Exception Handling topic in section Exception Handling & Static Class Members of Object Oriented Programming |
|
Answer» CORRECT choice is (a) Exception will be PRODUCED To explain: The exceptions are produced when anything unexpected happened. The program might not be ABLE to find a FILE in the target LOCATION and hence program produces an exceptions. The exception produced, then terminates the program. |
|