Explore topic-wise MCQs in Placement Tests.

This section includes 765 Mcqs, each offering curated multiple-choice questions to sharpen your Placement Tests knowledge and support exam preparation. Choose a topic below to get started.

301.

Which class is thread-safe i.e. multiple threads cannot access it simultaneously,So it is safe and will result in an order?

A. StringBuffer class
B. StringBuilder class
C. Both A & B
D. None of the above
Answer» B. StringBuilder class
302.

Hibernate caching improves the performance of the application by pooling the object in the cache.

A. True
B. False
Answer» B. False
303.

Which pattern is the struts framework based?

A. MVC2 Pattern
B. Bridge Pattern
C. MVC 1 Pattern
D. None of the above
Answer» B. Bridge Pattern
304.

JMS is also known as a messaging service.

A. True
B. False
Answer» B. False
305.

Which program obtains a remote reference to one or more remote objects on a server and then invokes methods on them in an RMI application?

A. Server
B. Client
C. Both A & B
D. None of the above
Answer» C. Both A & B
306.

XML stands for?

A. Extensible Markup Language
B. Extended Mashup Language
C. Extensible Mashup Language
D. X-Markup Language
Answer» B. Extended Mashup Language
307.

Which is used about text data that should not be parsed by the XML parser?

A. CDATA
B. PCDATA
C. None of the above
D. Both A & B
Answer» B. PCDATA
308.

Which class automatically flushes the data so that there is no need to call the flush() method. Moreover, its methods don't throw IOException?

A. Console class
B. Scanner Class
C. FileInputStream class
D. PrintStream class
Answer» E.
309.

Which is a superclass of all exception classes?

A. Throwable
B. Exception
C. RuntimeException
D. IOException
Answer» B. Exception
310.

Multiple inheritances is not supported in case of class but it is supported in case of interface.

A. True
B. False
Answer» B. False
311.

Which technology do we mix our business logic with the presentation logic?

A. Servlet
B. JSP
C. Both A & B
D. None of the above
Answer» B. JSP
312.

Which objects are used by RMI for communicating with the remote object?

A. Stub
B. Skeleton
C. Both A & B
D. None of the above
Answer» D. None of the above
313.

Which action tags are used in JSP for developing web application with Java Bean?

A. jsp:useBean
B. jsp:setProperty
C. jsp:getProperty
D. Both B & C
Answer» E.
314.

Which allows hyperlinks to point to specific parts (fragments) of XML documents?

A. XPath
B. XSLT
C. XLink
D. Xpointer
Answer» E.
315.

Which method is used for an SQL statement that is executed frequently?

A. prepareStatement
B. prepareCall
C. createStatement
D. None of the above
Answer» B. prepareCall
316.

Applet runs inside the browser and does not works at client side.

A. True
B. False
Answer» C.
317.

Which is a special type of program that is embedded in the webpage to generate the dynamic content?

A. Package
B. Applet
C. Browser
D. None of the above
Answer» C. Browser
318.

Both threads are waiting for each other to release the lock, the condition is called deadlock.

A. True
B. False
Answer» B. False
319.

Which state is the thread still alive, but is currently not eligible to run?

A. Non-Runnable
B. Terminated
C. Runnable
D. Running
Answer» B. Terminated
320.

Under which package is the string class encapsulated?

A. java.lang
B. java.util
C. java.io
D. java.awt
Answer» B. java.util
321.

How many ways are there to access package from another package?

A. 3
B. 2
C. 1
D. 5
Answer» B. 2
322.

How many types of controls does AWT support?

A. 7
B. 6
C. 5
D. 8
Answer» B. 6
323.

Which keyword is used for the block to handle the exceptions generated by try block?

A. Catch
B. Final
C. throw
D. try
Answer» B. Final
324.

Where does the primitive data type values be stored?

A. Heap Memory
B. Stack Memory
C. Both A & B
D. None of the above
Answer» C. Both A & B
325.

URL is an acronym for?

A. Uniform Resource Locator
B. Unified Resource Locator
C. Uniform Restore Locator
D. Unified Restore Locator
Answer» B. Unified Resource Locator
326.

Which language is case sensitive?

A. HTML
B. XML
C. Both A & B
D. None of the above
Answer» C. Both A & B
327.

Abbreviate the term DOM?

A. Developed Object Model
B. Document Object Model
C. Document Oriented Model
D. None of the above
Answer» C. Document Oriented Model
328.

What type of constructor is used to provide different values to the distinct objects?

A. Default constructor
B. Parameterized constructor
C. Overloading constructor
D. None of the above
Answer» C. Overloading constructor
329.

An XML parser converts an XML document into an XML DOM object, which can then be manipulated with JavaScript.

A. True
B. False
Answer» B. False
330.

Which HTTP Request method is non-idempotent?

A. GET
B. POST
C. BOTH A & B
D. None of the above
Answer» C. BOTH A & B
331.

JDBC stands for?

A. Java database connectivity
B. Java database concept
C. Java database communications
D. None of the above
Answer» B. Java database concept
332.

Which servlet does the struts framework use?

A. EntryServlet
B. StrutsServlet
C. ActionServlet
D. BasicServlet
Answer» D. BasicServlet
333.

What does the Session object hold?

A. First Level Cache
B. Second Level Cache
C. Both A & B
D. None of the above
Answer» B. Second Level Cache
334.

The following example shows which XML Syntax rule, (1) < note date=" 12/11/2007"> (2) < to>Tove< /to> (3) < from>Jani< /from> (4) < /note>

A. XML Attribute Values Must be Quoted
B. All XML Elements Must Have a Closing Tag
C. XML Tags are Case Sensitive
D. XML Elements Must be Properly Nested
Answer» B. All XML Elements Must Have a Closing Tag
335.

The getElementsByTagName() method is used to retrieve data from an XML document.

A. True
B. False
Answer» B. False
336.

Which keyword is used by classes to implement an interface?

A. import
B. implements
C. instance of
D. None of the above
Answer» C. instance of
337.

Which package includes StringTokenizer that tokenizes a string into independent words?

A. java.awt
B. java.applet
C. java.util
D. java.lang
Answer» D. java.lang
338.

JVM stands for?

A. Java Very Large Machine
B. Java Verified Machine
C. Java Very Small Machine
D. Java Virtual Machine
Answer» E.
339.

Which method waits for a thread to die?

A. stop()
B. start()
C. terminate()
D. join()
Answer» E.
340.

What will happen if we call the run() method directly instead of calling the start() method?

A. Each thread starts in a separate call stack.
B. Invoking the run() method from main thread, the run() method goes onto the current call stack rather than at the beginning of a new call stack.
C. Both A & B
D. None of the above
Answer» D. None of the above
341.

Which package includes all the standard classes of java?

A. java.lang
B. java.math
C. java.ref
D. java.util
Answer» B. java.math
342.

Which class is used when a program does not want to handle an exception?

A. Throws
B. Try
C. Catch
D. Final
Answer» B. Try
343.

How many types of constructor are defined in the StringTokenizer class?

A. 2
B. 3
C. 4
D. 5
Answer» C. 4
344.

What represents a persistent global data from the database?

A. Entity Bean
B. Session Bean
C. Both A & B
D. None of the above
Answer» B. Session Bean
345.

Which is the Microsoft solution for providing dynamic Web content?

A. ASP
B. JSP
C. Both A & B
D. None of the above
Answer» B. JSP
346.

Which of the following is an advantage of the statement – Separation of business logic from JSP ?

A. Custom Tags in JSP
B. JSP Standard Tag Library
C. All the above
D. None of the above
Answer» B. JSP Standard Tag Library
347.

Which is a mechanism where one object acquires all the properties and behaviors of the parent object?

A. Inheritance
B. Encapsulation
C. Polymorphism
D. None of the above
Answer» B. Encapsulation
348.

RMI Architecture consists of how many layers?

A. 5
B. 3
C. 4
D. 2
Answer» D. 2
349.

What is used to run an Applet?

A. An html file
B. An AppletViewer tool(for testing purpose)
C. Both A & B
D. None of the above
Answer» D. None of the above
350.

Which JDBC product components does the Java software provide?

A. The JDBC driver manager
B. The JDBC driver test suite
C. The JDBC-ODBC bridge
D. All mentioned above
Answer» E.