Computer Data Structure And Algorithm 2(TTA)

Reviewed by Editorial Team
The ProProfs editorial team is comprised of experienced subject matter experts. They've collectively created over 10,000 quizzes and lessons, serving over 100 million users. Our team includes in-house content moderators and subject matter experts, as well as a global network of rigorously trained contributors. All adhere to our comprehensive editorial guidelines, ensuring the delivery of high-quality content.
Learn about Our Editorial Process
| By Allexamreview06
A
Allexamreview06
Community Contributor
Quizzes Created: 4 | Total Attempts: 2,517
| Attempts: 133 | Questions: 25
Please wait...
Question 1 / 25
0 %
0/100
Score 0/100
1. When new data are to be inserted into a data structure, but there is no available space; this situation is usually called

Explanation

When new data are to be inserted into a data structure, but there is no available space, this situation is usually called "overflow." Overflow occurs when the data structure reaches its maximum capacity and cannot accommodate any more data. This can happen in various data structures such as arrays or queues. When an overflow occurs, it indicates that the data structure is full and cannot accept any additional data until some space is freed up.

Submit
Please wait...
About This Quiz
Computer Data Structure And Algorithm  2(TTA) - Quiz

INSTRUCTIONS
1. NUMBER OF QUESTIONS 25
2. HAS A TIME LIMIT OF 15 MINUTES
3. HAS A PASS MARKS OF 30%
4. QUESTIONS PER PAGE 1
5. EACH QUESTIONS HAS 1 MARKS
6. NEGATIVE MARKING FOR EACH QUESTIONS 0.25
7. WILL ALLOW TO YOU GO BACK ,SKIP AND CHANGE YOUR ANSWERS
8. WILL ALLOW TO YOU PRINT OUT... see moreYOUR RESULT AND CERTIFICATE
9. WILL ALLOW TO YOU PRINT OUT YOURS RESPONSE SHEET WITH CORRECT ANSWER KEY AND EXPLANATION
10. WE WILL PROVIDE YOURS RESULT,CERTIFICATE AND YOUR RESPONSE SHEET TO YOURS EMAIL ID AT END OF ONLINE TEST


.
.
.
. see less

2. An algorithm that calls itself directly or indirectly is known as

Explanation

Recursion is the correct answer because an algorithm that calls itself, either directly or indirectly, is known as a recursive algorithm. In recursion, a problem is divided into smaller subproblems, and the solution to each subproblem is obtained by solving smaller instances of the same problem. This process continues until a base case is reached, which allows the algorithm to terminate. Recursion is commonly used in programming to solve problems that can be broken down into smaller, similar subproblems.

Submit
3. Which of the following data structure can't store the non-homogeneous data elements?

Explanation

Arrays cannot store non-homogeneous data elements because they require all elements to be of the same data type. In an array, each element occupies a fixed amount of memory space, and the data type determines the size of that space. Therefore, if non-homogeneous data elements were allowed, it would be difficult to allocate the appropriate amount of memory for each element. In contrast, records and pointers can store non-homogeneous data elements because they allow for different data types to be stored within a single structure or variable.

Submit
4. Which data structure allows deleting data elements from front and inserting at rear?

Explanation

Queues are a type of data structure that allows deleting data elements from the front and inserting new elements at the rear. In a queue, the first element that is inserted is the first one to be removed, following the First-In-First-Out (FIFO) principle. This makes queues suitable for scenarios where elements need to be processed in the order they arrive, such as handling requests or tasks in a computer system. Stacks, on the other hand, follow the Last-In-First-Out (LIFO) principle, where the last element inserted is the first one to be removed. Deques and binary search trees do not have the specific functionality of deleting from the front and inserting at the rear.

Submit
5. The in order traversal of tree will yield a sorted listing of elements of tree in

Explanation

In a binary search tree, the in-order traversal will yield a sorted listing of elements. This is because the in-order traversal visits the left subtree first, then the root, and finally the right subtree. Since the elements in a binary search tree are arranged in a specific order where all elements in the left subtree are smaller than the root, and all elements in the right subtree are greater than the root, the in-order traversal will produce a sorted listing of the elements. Therefore, the correct answer is binary search trees.

Submit
6. The situation when in a linked list START=NULL is

Explanation

The situation when in a linked list START=NULL is referred to as underflow. This means that the linked list is empty and there are no elements present in it. In a linked list, the START pointer points to the first node of the list. When START=NULL, it indicates that there are no nodes in the list, resulting in underflow.

Submit
7. In a graph if e=(u, v) means

Explanation

The correct answer is "both e begins at u and ends at v and u is processor and v is successor". This answer combines both conditions mentioned in the question. It states that e begins at u and ends at v, indicating the direction of the edge. Additionally, it states that u is the processor and v is the successor, implying the relationship between the two vertices in terms of their roles or positions in a system or network.

Submit
8. Which of the following name does not relate to stacks?

Explanation

The name "FIFO lists" does not relate to stacks because stacks follow the LIFO (Last-In, First-Out) principle, while FIFO (First-In, First-Out) is the principle followed by queues. Stacks are a data structure where the last element added is the first one to be removed, while queues are a data structure where the first element added is the first one to be removed. Therefore, "FIFO lists" is not a name that relates to stacks.

Submit
9. Binary search algorithm can not be applied to

Explanation

Binary search algorithm cannot be applied to a sorted linked list because binary search requires random access to elements, which is not possible in a linked list. Binary search relies on dividing the search space in half at each step, but in a linked list, accessing elements in the middle of the list is not efficient. In contrast, binary search can be applied to sorted binary trees, sorted linear arrays, and pointer arrays because these data structures allow for efficient random access to elements.

Submit
10. If every node u in G is adjacent to every other node v in G, A graph is said to be

Explanation

A graph is said to be complete if every node in the graph is adjacent to every other node in the graph. This means that there is an edge connecting every pair of distinct nodes in the graph. In other words, there are no missing edges in a complete graph. Therefore, the given answer "complete" accurately describes the property of a graph where every node is adjacent to every other node.

Submit
11. A variable P is called pointer if

Explanation

A variable P is called a pointer if it contains the address of an element in DATA. This means that P is able to store the memory address of a specific element within the DATA. A pointer does not necessarily point to the address of the first element in DATA, nor does it store the entire DATA and its address. Its main purpose is to hold the address of a specific element within the DATA.

Submit
12. Identify the data structure which allows deletions at both ends of the list but insertion at only one end.

Explanation

An input-restricted deque is a data structure that allows deletions at both ends of the list but only allows insertion at one end. This means that elements can be removed from either the front or the back of the list, but new elements can only be added to one end of the list, typically the front. This restriction on insertion allows for efficient removal operations while maintaining a specific order of elements in the list.

Submit
13. A connected graph T without any cycles is called

Explanation

A connected graph T without any cycles is called a tree graph because it resembles a tree structure, with a single root node and branches extending outwards. It is also referred to as a free tree because it is free from any loops or cycles. Therefore, all of the given options - tree graph, free tree, and a tree - are correct descriptions for this type of graph.

Submit
14. A data structure where elements can be added or removed at either end but not in the middle

Explanation

A deque, or double-ended queue, is a data structure that allows elements to be added or removed at both ends. This means that elements can be added or removed at either end, but not in the middle. Linked lists, stacks, and queues also allow elements to be added or removed, but they do not have the capability to do so at both ends. Therefore, the correct answer is deque.

Submit
15. In a binary tree, certain null entries are replaced by special pointers which point to nodes higher in the tree for efficiency. These special pointers are called

Explanation

In a binary tree, certain null entries are replaced by special pointers called "thread" which point to nodes higher in the tree for efficiency. This allows for faster traversal of the tree as it eliminates the need to backtrack or navigate through unnecessary null entries. By using threads, the tree structure becomes more compact and efficient in terms of memory usage and traversal operations.

Submit
16. When inorder traversing a tree resulted E A C K F H D B G; the preorder traversal would return

Explanation

The inorder traversal of a binary tree visits the left subtree, then the root, and finally the right subtree. In this case, the inorder traversal resulted in E A C K F H D B G. The preorder traversal visits the root first, then the left subtree, and finally the right subtree. Therefore, the correct preorder traversal would be FAEKCDHGB.

Submit
17. A binary tree whose every node has either zero or two children is called

Explanation

An extended binary tree is a binary tree in which every node has either zero or two children. This means that there are no nodes with only one child in an extended binary tree. Therefore, the given answer is correct.

Submit
18. Which of the following sorting algorithm is of divide-and-conquer type?

Explanation

Quick sort is a sorting algorithm that follows the divide-and-conquer approach. It works by selecting a pivot element and partitioning the array into two sub-arrays, one with elements smaller than the pivot and the other with elements larger than the pivot. This process is recursively applied to the sub-arrays until the entire array is sorted. Therefore, Quick sort is the correct answer as it exemplifies the divide-and-conquer type of sorting algorithm.

Submit
19. Each data item in a record may be a group item composed of sub-items; those items which are indecomposable are called

Explanation

The correct answer is "all of these" because each data item in a record may indeed be a group item composed of sub-items, which are called elementary items. Additionally, indecomposable items are also referred to as atoms, and scalars are another term used to describe these items. Therefore, all three options are correct and applicable in this context.

Submit
20. To represent hierarchical relationship between elements, which data structure is suitable?

Explanation

A priority queue is suitable for representing a hierarchical relationship between elements. In a priority queue, each element is assigned a priority value, and the elements are organized in such a way that the element with the highest priority value is always at the front of the queue. This allows for efficient retrieval of the highest priority element, making it suitable for representing a hierarchical relationship where certain elements have higher priority than others. A deque (double-ended queue) does not inherently have a notion of priority, and therefore may not be suitable for representing a hierarchical relationship.

Submit
21. Which of the following data structure is non-linear type?

Explanation

All the options given in the question - Strings, Lists, and Stacks - are linear data structures because they organize data in a sequential manner. However, the correct answer is "None of these" because all the options mentioned are linear data structures, and the question asks for a non-linear data structure. Non-linear data structures, such as trees and graphs, do not organize data in a sequential manner and allow for more complex relationships between data elements.

Submit
22. Which of the following data structure store the homogeneous data elements?

Explanation

Records are a data structure that store homogeneous data elements. Unlike arrays, which store elements of the same data type, records can store elements of different data types. Records are often used to represent a collection of related data fields, such as a person's name, age, and address. Therefore, records are the correct answer for this question.

Submit
23. Which of the following is two way list?

Explanation

None of the options provided is a two way list. A two way list, also known as a doubly linked list, is a type of linked list where each node contains references to both the previous and next nodes in the list. However, none of the given options mention this characteristic.

Submit
24. The term "push" and "pop" is related to the

Explanation

The terms "push" and "pop" are commonly used in the context of stacks. In a stack, elements are added or removed from one end only. The "push" operation adds an element to the top of the stack, while the "pop" operation removes the top element from the stack. Arrays, lists, and stacks are all data structures, but the specific operations of "push" and "pop" are typically associated with stacks.

Submit
25. Which of the following data structure is linear type?

Explanation

None of the given options (Strings, Lists, Stacks) are linear data structures. Strings are a sequence of characters and not a data structure. Lists and Stacks are both examples of linear data structures, but they are not the only types. Other linear data structures include arrays, queues, and linked lists. Therefore, the correct answer is "None of these" as there are other linear data structures besides the ones mentioned in the options.

Submit
View My Results

Quiz Review Timeline (Updated): Jan 20, 2025 +

Our quizzes are rigorously reviewed, monitored and continuously updated by our expert board to maintain accuracy, relevance, and timeliness.

  • Current Version
  • Jan 20, 2025
    Quiz Edited by
    ProProfs Editorial Team
  • Sep 07, 2016
    Quiz Created by
    Allexamreview06
Cancel
  • All
    All (25)
  • Unanswered
    Unanswered ()
  • Answered
    Answered ()
When new data are to be inserted into a data structure, but there is...
An algorithm that calls itself directly or indirectly is known as
Which of the following data structure can't store the non-homogeneous...
Which data structure allows deleting data elements from front and...
The in order traversal of tree will yield a sorted listing of elements...
The situation when in a linked list START=NULL is
In a graph if e=(u, v) means
Which of the following name does not relate to stacks?
Binary search algorithm can not be applied to
If every node u in G is adjacent to every other node v in G, A graph...
A variable P is called pointer if
Identify the data structure which allows deletions at both ends of the...
A connected graph T without any cycles is called
A data structure where elements can be added or removed at either end...
In a binary tree, certain null entries are replaced by special...
When inorder traversing a tree resulted E A C K F H D B G; the...
A binary tree whose every node has either zero or two children is...
Which of the following sorting algorithm is of divide-and-conquer...
Each data item in a record may be a group item composed of sub-items;...
To represent hierarchical relationship between elements, which data...
Which of the following data structure is non-linear type?
Which of the following data structure store the homogeneous data...
Which of the following is two way list?
The term "push" and "pop" is related to the
Which of the following data structure is linear type?
Alert!

Advertisement