Multiple choice technology web technology

Is it possible to servlet have a constructor

  1. yes but then serlvet will not work properly ie can't provide initilization parameters

  2. not possible

  3. sometimes only

  4. none of these

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

Servlets can have constructors, but the servlet container always calls the no-argument constructor. If you define a constructor with parameters, the container cannot instantiate it properly and initialization parameters will not be available.