The Gateway to Computer Science Excellence
For all GATE CSE Questions
Toggle navigation
GATE Overflow
Facebook Login
or
Email or Username
Password
Remember
Login
Register

I forgot my password
Activity
Questions
Unanswered
Tags
Subjects
Users
Ask
Prev
Blogs
New Blog
Exams
First time here? Checkout the
FAQ
!
x
×
Close
Use the google search bar on side panel. It searches through all previous GATE/other questions. For hardcopy of previous year questions please see
here
Recent questions tagged datastructure
Webpage for Data Structures
0
votes
1
answer
1
Self doubt
I have a confusion regarding the array implementation of binary tree ,i.e what are the index locations of the left child of a node whether it is 2i+1 or 2i and same for right child ,can anyone explain?
asked
6 days
ago
in
DS
by
Winner
(
123
points)

38
views
datastructure
0
votes
1
answer
2
Internal Path Length of BST
Consider the following binary tree with root at level 0. What is the internal path length for the above tree? 31 14 29 32
asked
Mar 10
in
Algorithms
by
s_dr_13
(
93
points)

49
views
bst
binarysearchtree
tree
datastructure
0
votes
0
answers
3
Hashing
Consider an open address hash table with uniform hashing. Out of 10 locations, 8 are occupied. What are the expected number of probes in an unsuccessful and successful search respectively?
asked
Mar 6
in
Algorithms
by
s_dr_13
(
93
points)

54
views
hashing
datastructure
uniformhashing
probability
0
votes
2
answers
4
GATE201940
Consider the following statements: The smallest element in a maxheap is always at a leaf node The second largest element in a maxheap is always a child of a root node A maxheap can be constructed from a binary search tree in $\theta(n)$ time A binary search tree can be ... time Which of te above statements are TRUE? I, II and III I, II and IV I, III and IV II, III and IV
asked
Feb 7
in
DS
by
Arjun
Veteran
(
386k
points)

1.9k
views
gate2019
datastructure
heap
+3
votes
6
answers
5
GATE201946
Let $T$ be a full binary tree with $8$ leaves. (A full binary tree has every level full.) Suppose two leaves $a$ and $b$ of $T$ are chosen uniformly and independently at random. The expected value of the distance between $a$ and $b$ in $T$ (ie., the number of edges in the unique path between $a$ and $b$) is (rounded off to $2$ decimal places) _________.
asked
Feb 7
in
DS
by
Arjun
Veteran
(
386k
points)

4.2k
views
gate2019
numericalanswers
datastructure
binarytree
+1
vote
1
answer
6
BFS traversal path
What will be the path from AH if BFS is used in the following graph?
asked
Feb 2
in
Algorithms
by
saptarshiDey
(
83
points)

64
views
graphalgorithms
algorithms
bfs
datastructure
0
votes
1
answer
7
Made easy
The given answer is c, but how?
asked
Jan 29
in
Programming
by
Jyoti Kumari97
(
225
points)

60
views
datastructure
0
votes
0
answers
8
Made easy
asked
Jan 28
in
Programming
by
Jyoti Kumari97
(
225
points)

57
views
datastructure
queues
circularqueue
+1
vote
2
answers
9
ME FLT2
AVL tree is constructed by inserting the keys 2, 6, 1, 5, 3, 4, 7 in the given order. (Assume the tree is initially empty). Then the level order traversal of the above binary tree will be.. Answer given is: 3,2,5,1,4,6,7
asked
Jan 28
in
Programming
by
balchandar reddy san
Active
(
2.7k
points)

63
views
datastructure
0
votes
1
answer
10
Made easy tree height
The height of a binary tree is defined as the number of nodes in the longest path from root to the leaf node. Let X be the height of a complete binary tree with 256 nodes. Then the value of X will be Answer 9
asked
Jan 28
in
DS
by
Ram Swaroop
Active
(
2.5k
points)

56
views
datastructure
binarytree
0
votes
1
answer
11
ds and programming
when i printing x it is giving 0 but when comparing x with 5 ,it executing else part ,means condition fail ,why ?? #include <stdio.h> int main(void) { int x; if(x=(printf("Hello")) != 5) printf("Hello"); else printf("World \n"); printf("%d \n",x); return 0; } https://ideone.com/NJSj2i
asked
Jan 28
in
Programming
by
Gurdeep Saini
Loyal
(
9.1k
points)

50
views
datastructure
programminginc
output
+1
vote
0
answers
12
MadeEasy Full Length Test 2019: Programming & DS  DS
Q.Consider a 2 dimensional array A[40 ... 95, 40 ... 95] in lower triangular matrix representation. If the array is implemented in the memory in the form of row major order and base address of the array is 1000, then the address of A[66][50] will be ________.
asked
Jan 27
in
Programming
by
Badayayash
Junior
(
889
points)

65
views
datastructure
arrays
madeeasytestseries2019
madeeasytestseries
0
votes
1
answer
13
Self doubt
If there is negative edge cycle then dijkstra algorithm will give correct path or not same thing about bellman ford also? Bellman ford always halts or not?
asked
Jan 27
in
Programming
by
iamdeepakji
(
227
points)

31
views
data
datastructure
0
votes
0
answers
14
MadeEasy Test Series 2019: Programming & DS  Hashing
Consider the hashing table with 'm' slots and 'n' keys. If the expected number of probes in unsuccessful search is 3. The expected number of probes in a successful search is_ Answer 1.647
asked
Jan 27
in
DS
by
Ram Swaroop
Active
(
2.5k
points)

100
views
programminginc
datastructure
hashing
madeeasytestseries2019
madeeasytestseries
0
votes
0
answers
15
Binary Tree
I think its answer is 8 .Please ,can any one make it sure for me :)
asked
Jan 25
in
DS
by
Nandkishor3939
Active
(
1.2k
points)

55
views
datastructure
binarytree
0
votes
0
answers
16
Number of sub graphs possible
Number of labelled subgraphs possible for the graph given below______________
asked
Jan 25
in
DS
by
Nandkishor3939
Active
(
1.2k
points)

72
views
graphtheory
datastructure
+1
vote
0
answers
17
GATEBOOK2019 Mock Test149
Consider a data type whose elements are integers and whose operations are INSERT, DELETE, and FINDCLOSEST, with FINDCLOSEST(y) deﬁned to be some element x in the current set such that $xy ≤ x_iy $ for all $x_i$ in the current set. ... following data structures would be best to use in order to minimize T? A sorted list An unordered list An implicit heap An AVL tree
asked
Jan 19
in
Algorithms
by
GATEBOOK
Boss
(
15.3k
points)

140
views
gb2019mock1
datastructure
0
votes
1
answer
18
DS and programming
in a sorted array of n distinct element finding i th largest element take o(1) . true / false
asked
Jan 18
in
Programming
by
Gurdeep Saini
Loyal
(
9.1k
points)

68
views
datastructure
programminginc
easy
0
votes
0
answers
19
Insertion in Hash table. (M.E.)
The number of different insertion sequences of numbers $\left \{ 7,20,32,50,66,77 \right \}$ on an initially empty hash table H of size $6$ and a hash function $h\left ( k \right )=k\mod6$ with linear probing scheme for collision resolution such that the hash table obtained ... ${\color{Blue} {2}}$ ${\color{Blue} {3}}$. ${\color{Blue} {4}}$ ${\color{Blue} {5}}$
asked
Jan 16
in
DS
by
srestha
Veteran
(
109k
points)

119
views
hashing
datastructure
0
votes
0
answers
20
Binary tree
Consider a binary tree for every node  P  Q  <= 2. P represents number of nodes in left subtree of S and Q represents number of nodes in right subtree of S for h > 0. The minimum number of nodes present in such tree of height h = 4 ( Root at 0 level)
asked
Jan 16
in
Programming
by
Na462
Loyal
(
8.7k
points)

45
views
datastructure
binarytree
algorithms
madeeasytestseries
0
votes
0
answers
21
MeTestBST
When searching for the key value 50 in the binary search tree, node containing the key values 10,30,40,70,90,120,150,175 are traversed in any order.The number of different orders possible in which these keys values can occur on the search path from root to the node containing the value 50 are?
asked
Jan 16
in
Programming
by
Ayush Upadhyaya
Boss
(
24.9k
points)

98
views
datastructure
+2
votes
1
answer
22
How many Binary Search Trees are possible for a labelled nodes?
Let us there are n nodes which are labelled. Then the number of trees possible is given by the Catalan Number i.e $\binom{2n}{n} / (n+1)$ Then the binary search trees possible is just 1?
asked
Jan 16
in
DS
by
sripo
Active
(
1.5k
points)

113
views
algorithms
graphtheory
binarysearchtree
binarysearch
binarytree
trees
datastructure
0
votes
0
answers
23
DFS tree
Statement: DFS of an undirected graph contains tree edges and back edges but can never contain forward edges and cross ege. TRUE if it is a undirected graph then there is no difference between forward and backward edges hence above statement should be false, but it is given true. please clear my doubts
asked
Jan 15
in
Programming
by
harsh yadav
(
111
points)

27
views
datastructure
+2
votes
3
answers
24
DS and programming
#include <stdio.h> int arr[] = { 10, 20, 30, 40, 50 }; static int count ; inc() { return ++count; } int main() { arr[count++]=inc(); printf("%d ", arr[count]); printf("%d ", arr[0]); } https://ideone.com/5LOuqj
asked
Jan 14
in
Programming
by
Gurdeep Saini
Loyal
(
9.1k
points)

269
views
datastructure
programminginc
output
0
votes
0
answers
25
Madeeasy Max Heap 2019
Please explain the logic behind this shortcut and when to be used?
asked
Jan 13
in
Algorithms
by
Markzuck
Junior
(
633
points)

205
views
heap
datastructure
binaryheap
algorithms
madeeasytestseries
0
votes
0
answers
26
me test
Consider an initially empty hash table of length 10. Following set of keys are inserted using open addressing with hash function h(k) = k mod 10 and linear probing. The number of different insertion sequence of the key values using the given hash function and linear probing will result in the hash table shown in above? (given ans is 128 but i am getting 288)
asked
Jan 12
in
Programming
by
newdreamz a1z0
Active
(
1.7k
points)

60
views
datastructure
hashing
linear
probing
0
votes
0
answers
27
Madeaeasy
Total number of ordering possible with 12,10,8,5,3,2,1,7,9 such that if node of the below graph is filled with given elements , such that it satisfy MAXHeap property How to solve such question accurately
asked
Jan 11
in
Programming & DS
by
jatin khachane 1
Loyal
(
6.4k
points)

152
views
datastructure
heap
0
votes
0
answers
28
Postfix expression doubt
What is the significance of the underlined sentence ??
asked
Jan 9
in
DS
by
Nandkishor3939
Active
(
1.2k
points)

21
views
datastructure
0
votes
1
answer
29
AVL TREE
I am getting level order traversal(3,2,1,5,4,6,7)….. where i am wrong..??
asked
Jan 8
in
Algorithms
by
Vikas123
(
359
points)

68
views
avltree
datastructure
tree
bst
algorithms
0
votes
0
answers
30
PREORDER, POSTORDER INORDER
Acc. to (question) my solution is... uniquely constructed binary tree PRE+POST and IN+POST… where i am wrong….
asked
Jan 8
in
Algorithms
by
Vikas123
(
359
points)

44
views
treetraversal
datastructure
Page:
1
2
3
4
5
6
...
38
next »
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
Important Dates for Counselling (GATE 2019)
IIT Gandhinagar review
AIR175 : GO is enough
GATE 2019 My reasoned routine. (AIR 558)
if i can you also can
Follow @csegate
Recent questions tagged datastructure
Recent Blog Comments
75
Is doing ME in CS and SS from Bits Pilani...
can anybody compare it with other new iits such...
can i get a call on 580 (OBCNCL)
Many times Anger , Aggression and Fear push...
48,720
questions
52,807
answers
183,452
comments
68,470
users