Servlet Interview Questions and Answers
Question - 111 : - What is the major difference between Servlet and Applet?
Answer - 111 : - The major difference between Servlet and Applet is that the Servlet resides on the Server-side whereas the Applet resides on the client-side in the web browser.
Question - 112 : - Is it possible to have a Constructor inside the Servlet?
Answer - 112 : -
Yes, it is possible to define a constructor inside a servlet, but it can be called only by Servlet container and not explicitly.
Question - 113 : - Name the packages that work with Servlet?
Answer - 113 : -
There are basically two packages which work with Servlet as shown below:
- Javax.servlet
- Javax.servlet.http