Login
Register
@
Dark Mode
Profile
Edit my Profile
Messages
My favorites
Register
Activity
Q&A
Questions
Unanswered
Tags
Subjects
Users
Ask
Previous Years
Blogs
New Blog
Exams
Dark Mode
Recent questions tagged data-structures
48
votes
9
answers
1561
GATE CSE 2013 | Question: 50
The procedure given below is required to find and replace certain characters inside an input character string supplied in array $A$. The characters to be replaced are supplied in array $oldc$ ... given above, how many test cases will be able to capture the flaw? Only one Only two Only three All four
Arjun
asked
in
DS
Sep 24, 2014
by
Arjun
11.9k
views
gatecse-2013
data-structures
array
normal
27
votes
2
answers
1562
GATE CSE 2013 | Question: 43
The preorder traversal sequence of a binary search tree is $30, 20, 10, 15, 25, 23, 39, 35, 42$. Which one of the following is the postorder traversal sequence of the same tree? $10, 20, 15, 23, 25, 35, 42, 39, 30$ $15, 10, 25, 23, 20, 42, 35, 39, 30$ $15, 20, 10, 23, 25, 42, 35, 39, 30$ $15, 10, 23, 25, 20, 35, 42, 39, 30$
Arjun
asked
in
DS
Sep 24, 2014
by
Arjun
10.3k
views
gatecse-2013
data-structures
binary-search-tree
normal
20
votes
3
answers
1563
GATE CSE 1999 | Question: 12
In binary tree, a full node is defined to be a node with $2$ children. Use induction on the height of the binary tree to prove that the number of full nodes plus one is equal to the number of leaves. Draw the min-heap that results from insertion of the following ... empty min-heap: $7, 6, 5, 4, 3, 2, 1$. Show the result after the deletion of the root of this heap.
Kathleen
asked
in
DS
Sep 24, 2014
by
Kathleen
3.4k
views
gate1999
data-structures
heap
normal
descriptive
38
votes
4
answers
1564
GATE CSE 2013 | Question: 7
Which one of the following is the tightest upper bound that represents the time complexity of inserting an object into a binary search tree of $n$ nodes? $O(1)$ $O(\log n)$ $O(n)$ $O(n \log n)$
Arjun
asked
in
DS
Sep 23, 2014
by
Arjun
9.3k
views
gatecse-2013
data-structures
easy
binary-search-tree
21
votes
7
answers
1565
GATE CSE 2005 | Question: 36
In a complete $k$-ary tree, every internal node has exactly $k$ children. The number of leaves in such a tree with $n$ internal node is: $nk$ $(n-1)k + 1$ $n(k-1) +1$ $n(k-1)$
Kathleen
asked
in
DS
Sep 22, 2014
by
Kathleen
19.8k
views
gatecse-2005
data-structures
tree
normal
19
votes
1
answer
1566
GATE CSE 2005 | Question: 34
A priority queue is implemented as a Max-Heap. Initially, it has $5$ elements. The level-order traversal of the heap is: $10, 8, 5, 3, 2$. Two new elements $1$ and $7$ ... $10, 8, 7, 2, 3, 1, 5$ $10, 8, 7, 1, 2, 3, 5$ $10, 8, 7, 3, 2, 1, 5$
Kathleen
asked
in
DS
Sep 22, 2014
by
Kathleen
11.8k
views
gatecse-2005
data-structures
heap
normal
22
votes
3
answers
1567
GATE CSE 2005 | Question: 33
Postorder traversal of a given binary search tree, $T$ produces the following sequence of keys $10, 9, 23, 22, 27, 25, 15, 50, 95, 60, 40, 29$ Which one of the following sequences of keys can be the result of an in-order traversal of the tree $T$ ... $95, 50, 60, 40, 27, 23, 22, 25, 10, 9, 15, 29$
Kathleen
asked
in
DS
Sep 22, 2014
by
Kathleen
9.7k
views
gatecse-2005
data-structures
binary-search-tree
easy
43
votes
3
answers
1568
GATE CSE 2005 | Question: 5
A program $P$ reads in $500$ integers in the range $[0, 100]$ representing the scores of $500$ students. It then prints the frequency of each score above $50$. What would be the best way for $P$ to store the frequencies? An array of $50$ numbers An array of $100$ numbers An array of $500$ numbers A dynamically allocated array of $550$ numbers
Kathleen
asked
in
DS
Sep 22, 2014
by
Kathleen
17.4k
views
gatecse-2005
data-structures
array
easy
40
votes
7
answers
1569
GATE CSE 2005 | Question: 2
An Abstract Data Type (ADT) is: same as an abstract class a data type that cannot be instantiated a data type for which only the operations defined on it can be used, but none else all of the above
Kathleen
asked
in
DS
Sep 22, 2014
by
Kathleen
16.2k
views
gatecse-2005
data-structures
normal
abstract-data-type
21
votes
3
answers
1570
GATE CSE 2009 | Question: 59
Consider a binary max-heap implemented using an array. Which one of the following array represents a binary max-heap? $\left\{25,12,16,13,10,8,14\right\}$ $\left\{25,14,13,16,10,8,12\right\}$ $\left\{25,14,16,13,10,8,12\right\}$ $\left\{25,14,12,13,10,8,16\right\}$
Kathleen
asked
in
DS
Sep 22, 2014
by
Kathleen
11.2k
views
gatecse-2009
data-structures
heap
normal
35
votes
4
answers
1571
GATE CSE 2009 | Question: 37,ISRO-DEC2017-55
What is the maximum height of any AVL-tree with $7$ nodes? Assume that the height of a tree with a single node is $0$. $2$ $3$ $4$ $5$
Kathleen
asked
in
DS
Sep 22, 2014
by
Kathleen
37.4k
views
gatecse-2009
data-structures
binary-search-tree
normal
isrodec2017
avl-tree
28
votes
2
answers
1572
GATE CSE 2009 | Question: 36
The keys $12, 18, 13, 2, 3, 23, 5$ and $15$ are inserted into an initially empty hash table of length $10$ using open addressing with hash function $h(k) = k \mod 10$ ...
Kathleen
asked
in
DS
Sep 22, 2014
by
Kathleen
5.5k
views
gatecse-2009
data-structures
hashing
normal
60
votes
5
answers
1573
GATE CSE 2007 | Question: 47
Consider the process of inserting an element into a $Max \: Heap$, where the $Max \: Heap$ is represented by an $array$. Suppose we perform a binary search on the path from the new leaf to the root to find the position for the newly inserted element, the number of $comparisons$ performed is: $\Theta(\log_2n)$ $\Theta(\log_2\log_2n)$ $\Theta(n)$ $\Theta(n\log_2n)$
Kathleen
asked
in
DS
Sep 22, 2014
by
Kathleen
14.7k
views
gatecse-2007
data-structures
heap
normal
27
votes
4
answers
1574
GATE CSE 2007 | Question: 46
Consider the following C program segment where $CellNode$ represents a node in a binary tree: struct CellNode { struct CellNode *leftChild; int element; struct CellNode *rightChild; }; int Getvalue (struct CellNode *ptr) { int value = 0; if (ptr != NULL) ... in the tree the number of internal nodes in the tree the number of leaf nodes in the tree the height of the tree
Kathleen
asked
in
DS
Sep 22, 2014
by
Kathleen
6.6k
views
gatecse-2007
data-structures
binary-tree
normal
29
votes
8
answers
1575
GATE CSE 2007 | Question: 43
A complete $n-ary$ tree is a tree in which each node has $n$ children or no children. Let $I$ be the number of internal nodes and $L$ be the number of leaves in a complete $n-ary$ tree. If $L = 41$ and $I = 10$, what is the value of $n$? $3$ $4$ $5$ $6$
Kathleen
asked
in
DS
Sep 22, 2014
by
Kathleen
22.6k
views
gatecse-2007
data-structures
tree
normal
25
votes
2
answers
1576
GATE CSE 2007 | Question: 40
Consider a hash table of size seven, with starting index zero, and a hash function $(3x + 4)\mod 7$. Assuming the hash table is initially empty, which of the following is the contents of the table when the sequence $1, 3, 8, 10$ is inserted into the table using closed hashing? Note that − denotes an ... $3$ $1$, −, −, −, −, −, $3$ $1, 10, 8$, −, −, −,$ 3$
Kathleen
asked
in
DS
Sep 22, 2014
by
Kathleen
13.6k
views
gatecse-2007
data-structures
hashing
easy
17
votes
3
answers
1577
GATE CSE 2007 | Question: 39, UGCNET-June2015-II: 22
The inorder and preorder traversal of a binary tree are $\text{d b e a f c g}$ and $\text{a b d e c f g}$, respectively The postorder traversal of the binary tree is: $\text{d e b f g c a}$ $\text{e d b g f c a}$ $\text{e d b f g c a}$ $\text{d e f g b c a}$
Kathleen
asked
in
DS
Sep 22, 2014
by
Kathleen
6.7k
views
gatecse-2007
data-structures
binary-tree
normal
ugcnetcse-june2015-paper2
33
votes
4
answers
1578
GATE CSE 2007 | Question: 38, ISRO2016-27
The following postfix expression with single digit operands is evaluated using a stack: $8 \ 2 \ 3 \ {}^\hat{} ∕ \ 2 \ 3 * + 5 \ 1 * -$ Note that $^\hat{}$ is the exponentiation operator. The top two elements of the stack after the first $*$ is evaluated are $6, 1$ $5, 7$ $3, 2$ $1, 5$
Kathleen
asked
in
DS
Sep 22, 2014
by
Kathleen
14.1k
views
gatecse-2007
data-structures
stack
normal
infix-prefix
isro2016
28
votes
3
answers
1579
GATE CSE 2007 | Question: 13
The maximum number of binary trees that can be formed with three unlabeled nodes is: $1$ $5$ $4$ $3$
Kathleen
asked
in
DS
Sep 22, 2014
by
Kathleen
26.8k
views
gatecse-2007
data-structures
binary-tree
normal
23
votes
4
answers
1580
GATE CSE 2007 | Question: 12
The height of a binary tree is the maximum number of edges in any root to leaf path. The maximum number of nodes in a binary tree of height $h$ is: $2^h -1$ $2^{h-1} -1$ $2^{h+1} -1$ $2^{h+1}$
Kathleen
asked
in
DS
Sep 22, 2014
by
Kathleen
23.0k
views
gatecse-2007
data-structures
binary-tree
easy
67
votes
8
answers
1581
GATE CSE 2003 | Question: 23
In a min-heap with $n$ elements with the smallest element at the root, the $7^{th}$ smallest element can be found in time $\Theta (n \log n)$ $\Theta (n)$ $\Theta(\log n)$ $\Theta(1)$
Disha
asked
in
DS
Sep 19, 2014
by
Disha
26.0k
views
gatecse-2003
data-structures
heap
88
votes
11
answers
1582
GATE CSE 2004 | Question: 85
A program takes as input a balanced binary search tree with $n$ leaf nodes and computes the value of a function $g(x)$ for each node $x$. If the cost of computing $g(x)$ ... time complexity of the program is? $\Theta (n)$ $\Theta (n \log n)$ $\Theta(n^2)$ $\Theta (n^2\log n)$
Kathleen
asked
in
DS
Sep 19, 2014
by
Kathleen
22.0k
views
gatecse-2004
binary-search-tree
normal
data-structures
37
votes
3
answers
1583
GATE CSE 2004 | Question: 43
Consider the following C program segment struct CellNode{ struct CellNode *leftChild int element; struct CellNode *rightChild; }; int Dosomething (struct CellNode *ptr) { int value = 0; if(ptr != NULL) { if (ptr -> leftChild != NULL) value = 1 + ... leaf nodes in the tree The number of nodes in the tree The number of internal nodes in the tree The height of the tree
Kathleen
asked
in
DS
Sep 19, 2014
by
Kathleen
5.9k
views
gatecse-2004
data-structures
binary-tree
normal
55
votes
4
answers
1584
GATE CSE 2004 | Question: 40
Suppose each set is represented as a linked list with elements in arbitrary order. Which of the operations among $\text{union, intersection, membership, cardinality}$ will be the slowest? $\text{union}$ only $\text{intersection, membership}$ $\text{membership, cardinality}$ $\text{union, intersection}$
Kathleen
asked
in
DS
Sep 19, 2014
by
Kathleen
15.4k
views
gatecse-2004
data-structures
linked-list
normal
26
votes
3
answers
1585
GATE CSE 2004 | Question: 37
The elements $32, 15, 20, 30, 12, 25, 16,$ are inserted one by one in the given order into a maxHeap. The resultant maxHeap is
Kathleen
asked
in
DS
Sep 19, 2014
by
Kathleen
4.5k
views
gatecse-2004
data-structures
heap
normal
47
votes
8
answers
1586
GATE CSE 2004 | Question: 36
A circularly linked list is used to represent a Queue. A single variable $p$ is used to access the Queue. To which node should $p$ point such that both the operations $\text{enQueue}$ and $\text{deQueue}$ can be performed in constant time? rear node front node not possible with a single pointer node next to front
Kathleen
asked
in
DS
Sep 19, 2014
by
Kathleen
26.0k
views
gatecse-2004
data-structures
linked-list
normal
25
votes
3
answers
1587
GATE CSE 2004 | Question: 35
Consider the label sequences obtained by the following pairs of traversals on a labeled binary tree. Which of these pairs identify a tree uniquely? preorder and postorder inorder and postorder preorder and inorder level order and postorder I only II, III III only IV only
Kathleen
asked
in
DS
Sep 19, 2014
by
Kathleen
6.7k
views
gatecse-2004
data-structures
binary-tree
normal
20
votes
4
answers
1588
GATE CSE 2004 | Question: 7
Given the following input $(4322, 1334, 1471, 9679, 1989, 6171, 6173, 4199)$ and the hash function $x$ mod $10$, which of the following statements are true? $9679, 1989, 4199$ hash to the same value $1471, 6171$ hash to the same value All elements hash to the same value Each element hashes to a different value I only II only I and II only III or IV
Kathleen
asked
in
DS
Sep 19, 2014
by
Kathleen
7.8k
views
gatecse-2004
data-structures
hashing
easy
18
votes
3
answers
1589
GATE CSE 2004 | Question: 6
Level order traversal of a rooted tree can be done by starting from the root and performing preorder traversal in-order traversal depth first search breadth first search
Kathleen
asked
in
DS
Sep 19, 2014
by
Kathleen
4.8k
views
gatecse-2004
data-structures
tree
easy
19
votes
4
answers
1590
GATE CSE 2004 | Question: 5
The best data structure to check whether an arithmetic expression has balanced parentheses is a queue stack tree list
Kathleen
asked
in
DS
Sep 19, 2014
by
Kathleen
5.8k
views
gatecse-2004
data-structures
easy
stack
Page:
« prev
1
...
48
49
50
51
52
53
54
next »
Subscribe to GATE CSE 2023 Test Series
Subscribe to GO Classes for GATE CSE 2023
Quick search syntax
tags
tag:apple
author
user:martin
title
title:apple
content
content:apple
exclude
-tag:apple
force match
+apple
views
views:100
score
score:10
answers
answers:2
is accepted
isaccepted:true
is closed
isclosed:true
Recent Posts
DRDO Previous Year Papers
From Rank 4200 to 64: My Journey to Success in GATE CSE Exam
What are the key things to focus on during the final 10-15 days before the GATE exam to improve performance?
All India GO Classes Mock test
NTA UGC NET JRF December 2022 Apply Online Form 2023
Subjects
All categories
General Aptitude
(2.5k)
Engineering Mathematics
(9.3k)
Digital Logic
(3.3k)
Programming and DS
(5.9k)
Algorithms
(4.6k)
Theory of Computation
(6.7k)
Compiler Design
(2.3k)
Operating System
(5.0k)
Databases
(4.6k)
CO and Architecture
(3.8k)
Computer Networks
(4.6k)
Non GATE
(1.3k)
Others
(2.4k)
Admissions
(649)
Exam Queries
(842)
Tier 1 Placement Questions
(17)
Job Queries
(74)
Projects
(9)
Unknown Category
(853)
Recent questions tagged data-structures
Recent Blog Comments
Can Someone guide me how to prepare for interview...
It's not a standard resource, don't follow them.
https://byjus.com/maths/diagonalization/
@amit166 can you share the reference of the...
Twist at every point Man