Given a valid deployment descriptor (WEB.XML) containing the following code
<context-param>
<param-name>bestwebsite</param-name>
<param-value>www.examulator.com</param-value>
</context-param>
<
servlet>
<servlet-name>GetInitParameter</servlet-name>
<servlet-class>com.examulator.GetInitParameter</servlet-class>
<init-param>
<param-name>bestwebsite</param-name>
<param-value>www.javaranch.com</param-value>
</init-param>
</servlet>
And given that cfg is a valid ServletConfig object and ctx is a valid ServletContext object which of the following statements are true?
Choose at least one answer.
A. cfg.getInitParameter("bestwebsite") will return www.examulator.com
B. ctx.getInitParameter("bestwebsite") will return www.javaranch.com
C. ctx.getInitParameter("bestwebsite") will return www.examulator.com
D. cfg.getServletContext().getInitParameter("bestwebsite"); will cause a compile time error
E. ctx.getServletConfig().getInitParameter("bestwebsite"); will cause a compile time error
Answer is C only . I guess E option is also correct.