• +91 9971497814
  • info@interviewmaterial.com

Data structure Interview Questions Answers

Question 1 : What are the major data structures used in the following areas : RDBMS, Network data model & Hierarchical data model.

Answer 1 : 1. RDBMS Array (i.e. Array of structures) 2. Network data model Graph 3. Hierarchical data model Trees.

Question 2 : In RDBMS, what is the efficient data structure used in the internal storage representation?

Answer 2 : B+ tree. Because in B+ tree, all the data is stored only in leaf nodes, that makes searching easier. This corresponds to the records that shall be stored in leaf nodes.

Question 3 : List out few of the Application of tree data-structure?

Answer 3 : The manipulation of Arithmetic expression, Symbol Table construction, Syntax analysis.

Question 4 : What are the methods available in storing sequential files ?

Answer 4 : Straight merging, Natural merging,  Polyphase sort, Distribution of Initial runs.

Question 5 : What is the data structures used to perform recursion?

Answer 5 : Stack. Because of its LIFO (Last In First Out) property it remembers its caller, so knows whom to return when the function has to return. Recursion makes use of system stack for storing the return addresses of the function calls. Every recursive function has its equivalent iterative (non-recursive) function. Even when such equivalent iterative procedures are written, explicit stack is to be used.

Question 6 : What is data structure?

Answer 6 : A data structure is a way of organizing data that considers not only the items stored, but also their relationship to each other. Advance knowledge about the relationship between data items allows designing of efficient algorithms for the manipulation of data.

Question 7 : How is any Data Structure application is classified among files?

Answer 7 : A linked list application can be organized into a header file, source file and main application file. The first file is the header file that contains the definition of the NODE structure and the LinkedList class definition. The second file is a source code file containing the implementation of member functions of the LinkedList class. The last file is the application file that contains code that creates and uses the LinkedList class.

Question 8 : What member function places a new node at the end of the linked list?

Answer 8 : The appendNode() member function places a new node at the end of the linked list. The appendNode() requires an integer representing the current data of the node.

Question 9 : What is Linked List ?

Answer 9 : Linked List is one of the fundamental data structures. It consists of a sequence of? nodes, each containing arbitrary data fields and one or two (”links”) pointing to the next and/or previous nodes. A linked list is a self-referential datatype because it contains a pointer or link to another data of the same type. Linked lists permit insertion and removal of nodes at any point in the list in constant time, but do not allow random access.

Question 10 : What does each entry in the Link List called?

Answer 10 : Each entry in a linked list is called a node. Think of a node as an entry that has three sub entries. One sub entry contains the data, which may be one attribute or many attributes. Another points to the previous node, and the last points to the next node. When you enter a new item on a linked list, you allocate the new node and then set the pointers to previous and next nodes.

Data structure Contributors

krishan

Share your email for latest updates

Name:
Email:

Our partners