- Basic JSP Tutorial
- JSP - Home
- JSP - Overview
- JSP - Environment Setup
- JSP - Architecture
- JSP - Lifecycle
- JSP - Syntax
- JSP - Directives
- JSP - Actions
- JSP - Implicit Objects
- JSP - Client Request
- JSP - Server Response
- JSP - Http Status Codes
- JSP - Form Processing
- JSP - Writing Filters
- JSP - Cookies Handling
- JSP - Session Tracking
- JSP - File Uploading
- JSP - Handling Date
- JSP - Page Redirect
- JSP - Hits Counter
- JSP - Auto Refresh
- JSP - Sending Email
- Advanced JSP Tutorials
- JSP - Standard Tag Library
- JSP - Database Access
- JSP - XML Data
- JSP - Java Beans
- JSP - Custom Tags
- JSP - Expression Language
- JSP - Exception Handling
- JSP - Debugging
- JSP - Security
- JSP - Internationalization
- JSP Useful Resources
- JSP - Questions and Answers
- JSP - Quick Guide
- JSP - Useful Resources
- JSP - Discussion
JSP Online Quiz
Following quiz provides Multiple Choice Questions (MCQs) related to JSP Fundamentals. You will have to read all the given answers and click over the correct answer. If you are not sure about the answer then you can check the answer using Show Answer button. You can use Next Quiz button to check new set of questions in the quiz.
Q 1 - Which of the following is not a implicit object?
Answer : C
Explaination
There is no cookie object in jsp.
Answer : B
Explaination
jsp is a server side technology.
Q 3 - Which is the methods of generated Servlet?
Answer : D
Explaination
All of the above methods get generated in generated servlet.
Q 4 - Which of the following is an implicit object?
Answer : A
Explaination
pageContext is an implicit object.
Q 5 - What is true about filters?
Answer : C
Explaination
JSP Filters are Java classes that can be used in JSP Programming for both of the above purposes.
Answer : A
Explaination
A value of true (default) indicates automatic buffer flushing and a value of false throws an exception.
Q 7 - Which of the following is true about session Attribute?
A - The session attribute indicates whether or not the JSP page uses HTTP sessions.
B - A value of true means that the JSP page has access to a builtin session object.
C - A value of false means that the JSP page cannot access the builtin session object.
Answer : D
Explaination
The session attribute indicates whether or not the JSP page uses HTTP sessions. A value of true means that the JSP page has access to a builtin session object and a value of false means that the JSP page cannot access the builtin session object.
Q 8 - Which of the following depicts correct order of phases in JSP life cycle?
A - Compilation, Initialization, Execution, Cleanup
B - Initialization, Compilation, Cleanup, Execution
Answer : A
Explaination
Compilation, Initialization, Execution, Cleanup is the correct order.
Q 9 - What is difference between <%-- comment --%> and <!-- comment -->?
A - <%-- comment --%> is JSP comment. <!-- comment --> is an HTML comment.
B - <%-- comment --%> is ignored by JSP container.
Answer : D
Explaination
Q 10 - What is the use of <c:set > tag?
A - It can save values to database.
B - It evaluates an expression and uses the results to set a value of a JavaBean.
Answer : B
Explaination
The <c:set > tag is JSTL-friendly version of the setProperty action. The tag is helpful because it evaluates an expression and uses the results to set a value of a JavaBean or a java.util.Map object.