Pratice Question For Test AJP With Answer
Pratice Question For Test AJP With Answer
Pratice Question For Test AJP With Answer
SCHEME: I SEMESTER: V
NAME OF SUBJECT: ADVANCE JAVA PROGRAMMING
Subject Code: 22517
Q. 1 is a small piece of information that is passed back & forth in HTTP request & response.
(a) Servlet
(b) Applet
(c) Cookie
(d) Session
Answer: c
Q. 4 Apache Tomcat is .
(a) Servlet
(b) Java Program
(c) API
(d) Web server capable of running Java programs
Answer: d
(c) Creates new session if, the session does not exist
(d) The session is exist
Answer: c
Q.7 The package contains classes that help in connecting to a database, sending SQL
statem en ts to the database and process the query reque st.
(a) connection.sql
(b) db.sql
(c) pkg.sql
(d) java.sql
Answer: a
Q. 9 In JDBC imports all Java classes that are concern with Database connectivity.
(a) javax.sql
(b) java.mysql
(c) java.sql
(d) com.sql
Answer: c
15. Which class provides stream to read binary data such as image et(c) from the request
object?
A. ServletInputStream c. ServletOutputStream
b. Both a & b d. None Of Above
a) 2 c) 4
b) 5 d) 3
23. Which of the following is true about TCP protocol?.
a. is reliable and connection C.is unreliable but connection oriented
oriented D. None of these
B. is reliable and connectionless
(b) SocketImplFactory
(c) FileNameMa p and URLStreamHandlerFactory
(d) All of the above
Answer: d
Q. 37 IPv6 uses .
(a) 4 groups of 8 bits each
(b) 4 group of 8 hexa‐ decimal digits
(c) 8 groups of 4 digits each
(d) 8 groups of 4 hexa‐ decimal digits each
Answer: d
(a) returns the port number on which this request was received.
(b) returns the port name on which the request was received.
(c) returns the server number on which this request was received.
(d) returns the port number on which this response/req uest was received.
Answer: d
Q. 44 In this constructor ServerSocket(int port, int max_queue) what is the default value for max_queue?
(a) 100
(b) 50
(c) 75
(d) 80
Answer: b