Languages-Java [3i Infotech Placement]: Sample Questions 111 - 115 of 141

Glide to success with Doorsteptutor material for competitive exams : get questions, notes, tests, video lectures and more- for all subjects of your exam.

Question 111

Edit

Write in Short

Short Answer▾

What is meant by static query and dynamic query?

Explanation

Static Query

  • A result that never changes.
  • Based on information that matched the criteria from the moment when the query was done.

Dynamic Query

Updated with criteria each time it is run.

Question 112

Edit

Write in Short

Short Answer▾

What is the root class for all java classes?

Explanation

Object is root class of all the java classes.

Question 113

Edit

Write in Short

Short Answer▾

What are session variable in servlets?

Explanation

  • Variable used for set of requests or for a single site visit is known as session variable.
  • For example, user selection in a shopping cart stored with the help of session.

Two functions are associated with session variable:

Two Functions of Session Variable

Question 114

Edit

Describe in Detail

Essay▾

What are the files generated after using IDL to java compiler?

Explanation

If idl file name is My. idl, then when compiled following files will be generated:

  1. My. java
  2. MyHelper. java
  3. MyHolder. java
  4. MyOperations. java
  5. _MyStub. javal
The Idl File Name

Question 115

Edit

Describe in Detail

Essay▾

What are the traverses in binary tree?

Explanation

In-Order Traversal:

  • The left subtree is visited first, then the root and later the right sub-tree.
  • Outputs sorted key values in ascending order.

Algorithm

  • Recursively traverses left subtree.
  • Visit root node.
  • Recursively traverse right subtree.
Dfine In-Order Algorithm

Pre-order Traversal:

  • Root node is visited first, then the left subtree and finally the right subtree.

Algorithm:

  • Visit root node.
  • Recursively traverse left subtree.
  • Recursively traverse right subtree.
Define Pre-Order Traversal

Post-order Traversal

  • The root node is visited last, hence the name.
  • First we traverse the left subtree, then the right subtree and finally the root node.

Algorithm:

  • Recursively traverse left subtree.
  • Recursively traverse right subtree.
  • Visit root node.
Define Post-Order Traversal

Developed by: