Corresponding Answers with Surety of
100% Pass Mark
The method getWriter returns an object of type PrintWriter. This class has
println methods to generate output. Which of these classes define the
getWriter method? Select one correct answer.
A. HttpServletRequest
B. HttpServletResponse
C. ServletConfig
D. ServletContext - 🧠ANSWER ✔✔B
For application and session JSP scopes, what class of object is used to
store the attributes? (Choose one)
A. ServletContext and HttpSession respectively.
B. HttpSession for both.
C. ServletContext for both.
D. HttpSession and ServletContext respectively - 🧠ANSWER ✔✔A
COPYRIGHT©JOSHCLAY 2025/2026. YEAR PUBLISHED 2025. COMPANY REGISTRATION NUMBER: 619652435. TERMS OF USE. PRIVACY 1
STATEMENT. ALL RIGHTS RESERVED
,The /WEBINF/tags and /WEB-INF/tld directories are reserved for holding
JSP tag fles and tag library descriptors, respectively. Is this true?
A. True
B. False - 🧠ANSWER ✔✔A
Standard Java EE web applications are deployed as:
A. WAR files
B. JAR files
C. DLL files
D. CLASS files - 🧠ANSWER ✔✔A
What are the components of Java Web Application?
A. Servlets
B. Jsps
C. Html
D. Media files
E. All - 🧠ANSWER ✔✔E
COPYRIGHT©JOSHCLAY 2025/2026. YEAR PUBLISHED 2025. COMPANY REGISTRATION NUMBER: 619652435. TERMS OF USE. PRIVACY 2
STATEMENT. ALL RIGHTS RESERVED
, A JSP page called test.jsp is passed a parameter name in the URL using
http://localhost/Final/test.jsp?name=John. The test.jsp contains the
following code.
<% String myName=request.getParameter("name");%>
<% String test= "Welcome " + myName; %>
<%=test%>
A. The page display "Welcome John"
B. The program gives a syntax error because of the statement <% String
myName=request.getParameter("name");%>
C. The program gives a syntax error because of the statement <% String
test= "Welcome " + myName; %>
D. The program gives a syntax error because of the statement <%=test%>
- 🧠ANSWER ✔✔A
Session death can come about through an explicit call (in Servlet code) to
HttpSession.invalidate().
A. True
B. False - 🧠ANSWER ✔✔A
COPYRIGHT©JOSHCLAY 2025/2026. YEAR PUBLISHED 2025. COMPANY REGISTRATION NUMBER: 619652435. TERMS OF USE. PRIVACY 3
STATEMENT. ALL RIGHTS RESERVED