Java EE 7 Application Developer — Question 63

Which two statements are true about the relationship between JavaServer Pages (JSP) and servlets? (Choose two.)

Answer options

Correct answer: A, D

Explanation

Option A is correct because JSP pages are compiled into servlets that extend the HTTPServlet class. Option D is also correct as JSP pages are ultimately translated into servlet code, which requires them to conform to specific formats. Options B and C are incorrect; while a JSP page has access to servlet context, it does not necessarily extend the same class, and JSP pages are compiled by the server, not directly interpreted by JSPServlet.