在Java Web应用程序中,给定一个Servlet的代码片段如下: public void doGet(HttpServletRequest request,HttpServletResponse response) throws ServletEx

admin2018-06-14  12

问题 在Java Web应用程序中,给定一个Servlet的代码片段如下:
public void doGet(HttpServletRequest request,HttpServletResponse response)
throws ServletException,IOException
{
---------------------
out.println("hi kitty!");
out.close(   );
}
运行此Servlet下划线处添加如下(    )代码.

选项 A、PrintWriter out=response.getWriter();
B、PrintWriter out=request.getWriter();
C、OutputStream out=response.getOutputStream();
D、OutputStream out=request.getWriter();

答案A

解析
转载请注明原文地址:https://jikaoti.com/ti/Rm0iFFFM
0

最新回复(0)