Error Handling interview questions

15 Error Handling questions from the PHP bank, written for Indian campus drives and tech interviews. Every question has a verified answer and an AI-tutor explanation on placd.

Free to start: the 2-minute IT readiness check — six questions and a result.

Take the free IT readiness check

or take a mock interview set up for this area

1. What is Exception?

Junior
  1. A.an object representing an anomalous condition that is thrown to interrupt normal flow and caught by a surrounding handler block
  2. B.the base interface, implemented by both Error and Exception, that any object must satisfy to be usable with the throw statement
  3. C.an optional clause after try and catch whose code always runs whether or not an exception was thrown, typically used for cleanup
  4. D.passing a previous throwable as the third constructor argument so the original cause is preserved and retrievable while a new exception is raised

Answer + AI explanation with Pro

2. Which term means: "an object representing an anomalous condition that is thrown to interrupt normal flow and caught by a surrounding handler block"?

Junior
  1. A.Exception
  2. B.finally block
  3. C.Throwable
  4. D.Exception chaining

Answer + AI explanation with Pro

3. Which statement is correct?

Junior
  1. A.Exception — passing a previous throwable as the third constructor argument so the original cause is preserved and retrievable while a new exception is raised
  2. B.Exception — an object representing an anomalous condition that is thrown to interrupt normal flow and caught by a surrounding handler block
  3. C.Exception — an optional clause after try and catch whose code always runs whether or not an exception was thrown, typically used for cleanup
  4. D.Exception — the hierarchy introduced in PHP 7 for internal engine problems such as type mismatches and calls to undefined functions, kept separate from user-level exceptions

Answer + AI explanation with Pro

4. What is finally block?

Mid
  1. A.the hierarchy introduced in PHP 7 for internal engine problems such as type mismatches and calls to undefined functions, kept separate from user-level exceptions
  2. B.the base interface, implemented by both Error and Exception, that any object must satisfy to be usable with the throw statement
  3. C.an optional clause after try and catch whose code always runs whether or not an exception was thrown, typically used for cleanup
  4. D.an object representing an anomalous condition that is thrown to interrupt normal flow and caught by a surrounding handler block

Answer + AI explanation with Pro

5. Which term means: "an optional clause after try and catch whose code always runs whether or not an exception was thrown, typically used for cleanup"?

Mid
  1. A.Exception
  2. B.finally block
  3. C.Throwable
  4. D.Error class

Answer + AI explanation with Pro

6. Which statement is correct?

Mid
  1. A.finally block — an object representing an anomalous condition that is thrown to interrupt normal flow and caught by a surrounding handler block
  2. B.finally block — an optional clause after try and catch whose code always runs whether or not an exception was thrown, typically used for cleanup
  3. C.finally block — the base interface, implemented by both Error and Exception, that any object must satisfy to be usable with the throw statement
  4. D.finally block — the hierarchy introduced in PHP 7 for internal engine problems such as type mismatches and calls to undefined functions, kept separate from user-level exceptions

Answer + AI explanation with Pro

7. What is Throwable?

Mid
  1. A.the base interface, implemented by both Error and Exception, that any object must satisfy to be usable with the throw statement
  2. B.an object representing an anomalous condition that is thrown to interrupt normal flow and caught by a surrounding handler block
  3. C.passing a previous throwable as the third constructor argument so the original cause is preserved and retrievable while a new exception is raised
  4. D.the hierarchy introduced in PHP 7 for internal engine problems such as type mismatches and calls to undefined functions, kept separate from user-level exceptions

Answer + AI explanation with Pro

8. Which term means: "the base interface, implemented by both Error and Exception, that any object must satisfy to be usable with the throw statement"?

Mid
  1. A.finally block
  2. B.Exception chaining
  3. C.Exception
  4. D.Throwable

Answer + AI explanation with Pro

9. Which statement is correct?

Mid
  1. A.Throwable — the hierarchy introduced in PHP 7 for internal engine problems such as type mismatches and calls to undefined functions, kept separate from user-level exceptions
  2. B.Throwable — an optional clause after try and catch whose code always runs whether or not an exception was thrown, typically used for cleanup
  3. C.Throwable — passing a previous throwable as the third constructor argument so the original cause is preserved and retrievable while a new exception is raised
  4. D.Throwable — the base interface, implemented by both Error and Exception, that any object must satisfy to be usable with the throw statement

Answer + AI explanation with Pro

10. What is Error class?

Mid
  1. A.an optional clause after try and catch whose code always runs whether or not an exception was thrown, typically used for cleanup
  2. B.an object representing an anomalous condition that is thrown to interrupt normal flow and caught by a surrounding handler block
  3. C.passing a previous throwable as the third constructor argument so the original cause is preserved and retrievable while a new exception is raised
  4. D.the hierarchy introduced in PHP 7 for internal engine problems such as type mismatches and calls to undefined functions, kept separate from user-level exceptions

Answer + AI explanation with Pro

11. Which term means: "the hierarchy introduced in PHP 7 for internal engine problems such as type mismatches and calls to undefined functions, kept separate from user-level exceptions"?

Mid
  1. A.Error class
  2. B.Throwable
  3. C.Exception
  4. D.finally block

Answer + AI explanation with Pro

12. Which statement is correct?

Mid
  1. A.Error class — an object representing an anomalous condition that is thrown to interrupt normal flow and caught by a surrounding handler block
  2. B.Error class — the base interface, implemented by both Error and Exception, that any object must satisfy to be usable with the throw statement
  3. C.Error class — passing a previous throwable as the third constructor argument so the original cause is preserved and retrievable while a new exception is raised
  4. D.Error class — the hierarchy introduced in PHP 7 for internal engine problems such as type mismatches and calls to undefined functions, kept separate from user-level exceptions

Answer + AI explanation with Pro

13. What is Exception chaining?

Senior
  1. A.the hierarchy introduced in PHP 7 for internal engine problems such as type mismatches and calls to undefined functions, kept separate from user-level exceptions
  2. B.an object representing an anomalous condition that is thrown to interrupt normal flow and caught by a surrounding handler block
  3. C.the base interface, implemented by both Error and Exception, that any object must satisfy to be usable with the throw statement
  4. D.passing a previous throwable as the third constructor argument so the original cause is preserved and retrievable while a new exception is raised

Answer + AI explanation with Pro

14. Which term means: "passing a previous throwable as the third constructor argument so the original cause is preserved and retrievable while a new exception is raised"?

Senior
  1. A.Throwable
  2. B.Error class
  3. C.finally block
  4. D.Exception chaining

Answer + AI explanation with Pro

15. Which statement is correct?

Senior
  1. A.Exception chaining — an optional clause after try and catch whose code always runs whether or not an exception was thrown, typically used for cleanup
  2. B.Exception chaining — passing a previous throwable as the third constructor argument so the original cause is preserved and retrievable while a new exception is raised
  3. C.Exception chaining — an object representing an anomalous condition that is thrown to interrupt normal flow and caught by a surrounding handler block
  4. D.Exception chaining — the base interface, implemented by both Error and Exception, that any object must satisfy to be usable with the throw statement

Answer + AI explanation with Pro

Free to start

Start with a free readiness check

Sign up free for the 2-minute IT readiness check and a scored result. Answers, explanations and the AI tutor on every Error Handling question come with Pro.

Take the free IT readiness check

or take a mock interview set up for this area

24,000+ questions & coding problemsSoftware & IT16,274 questionsGovernment jobs26 examsAptitudenew questions every timeAI practice interviewwith feedback65 topics to practiseMechanical1,149 questionsGATE ME9 papersEngineering Mathematics381 questions2-minute checkfreeDSA Problems1,422Civil1,005 questionsGATE CE9 papersCS Fundamentals1,209 questionsYour scores6 skillsSystem Design25Electrical / EEE1,047 questionsGATE EE9 papersRun your codeC++ · Java · PythonLow-Level Design144Electronics & Comm.975 questionsGATE EC9 papersAI help on every questionFull-Stack6,282Chemical1,005 questionsGATE CH9 papersAI whiteboardsystem designWork abroadEurope · remote · transfersESE ME1 paperGATE practice papers2019–2026ESE CE1 paperDate alertsbefore the last dateESE EE1 paperBehavioural courseHR round practiceESE ET1 paperResume optimizerProSSC JE ME1 paperApplication trackerSSC JE CE1 paperCompany-wise prepSSC JE EE1 paperRole roadmapsRRB JE1 subjectPriced in ₹UPI · cardsISRO SC1 paperGATE CS9 papersIBPS SO IT1 paperUGC NET CS1 paperSSC CGL26 papersIBPS PO26 papersRRB NTPC26 papersSSC CHSL26 papersIBPS Clerk26 papersSBI Clerk26 papersRRB Group D26 papersSSC CPO26 papersSSC GD26 papers