Login
Register
Dark Mode
Brightness
Profile
Edit Profile
Messages
My favorites
My Updates
Logout
Recent questions tagged data-structures
3
votes
1
answer
1231
quadratic probing collison loop count??
Given the input sequence {11,33,43,79,19} and hash table of size 10 with the hash function h(k)=k mod 10. If hash tables uses quadratic probing,the number of collisions occured while mapping the given sequence is?
Given the input sequence {11,33,43,79,19} and hash table of size 10 with the hash function h(k)=k mod 10. If hash tables uses quadratic probing,the number of collisions o...
firki lama
1.2k
views
firki lama
asked
Jan 17, 2017
DS
hashing
data-structures
+
–
0
votes
1
answer
1232
ace mock test
How many binary search trees can be formed with n distinct and designated(labeled) nodes...??
How many binary search trees can be formed with n distinct and designated(labeled) nodes...??
iita
364
views
iita
asked
Jan 17, 2017
DS
data-structures
binary-search-tree
ace-test-series
+
–
5
votes
4
answers
1233
Complexity of AVL
What is the worst case time complexity to construct an AVL tree from an array which satisfies the min heap property ? a) O(n log n) b) O(n2) c) O(n2 log n) d) O(n)
What is the worst case time complexity to construct an AVL tree from an array which satisfies the min heap property ?a) O(n log n)b) O(n2)c) O(n2 log n)d) O(n)
srestha
5.8k
views
srestha
asked
Jan 16, 2017
DS
data-structures
avl-tree
time-complexity
+
–
1
votes
0
answers
1234
MadeEasy Subject Test: Programming & DS - Binary Tree
# plz explain why option B is false ??
# plz explain why option B is false ??
Hradesh patel
269
views
Hradesh patel
asked
Jan 16, 2017
DS
made-easy-test-series
data-structures
binary-tree
+
–
7
votes
1
answer
1235
Testbook Test Series: Programming & DS - Binary Search Tree
In a binary search tree, the key with value $5$ was searched after traversing nodes with values $1, 3, 4, 6, 7, 8, 9$ not necessarily in this order. Lets $P$ is the probability that $3rd$ element on the search path ... different orders possible in which given nodes can be traversed before finding node with value $5$. Find $\frac{N}{10}+P$
In a binary search tree, the key with value $5$ was searched after traversing nodes with values $1, 3, 4, 6, 7, 8, 9$ not necessarily in this order. Lets $P$ is the proba...
Pankaj Joshi
1.1k
views
Pankaj Joshi
asked
Jan 16, 2017
Programming in C
testbook-test-series
probability
data-structures
binary-search-tree
combinatory
+
–
2
votes
1
answer
1236
Test by Bikram | Mock GATE | Test 1 | Question: 32
Fill in the blanks in the procedure: void Prod (Element Type X, Priority Queue H) { int i; if (IsFull(H)) { Error ("Priority queue is full"); return; } for (i=++H -> size; H -> Elements [i/2]>X; i/=2) _________________ } ... 2]=H$\rightarrow$ Elements $[i/2]$; $H$\rightarrow$ Elements $[i^2 ]=X;$ $H$\rightarrow$ Elements $[i]=X;$
Fill in the blanks in the procedure:void Prod (Element Type X, Priority Queue H) { int i; if (IsFull(H)) { Error ("Priority queue is full"); return; } for (i=++H - size; ...
Bikram
1.1k
views
Bikram
asked
Jan 16, 2017
GATE
tbb-mockgate-1
data-structures
priority-queue
+
–
0
votes
1
answer
1237
Test by Bikram | Mock GATE | Test 1 | Question: 27
Consider the following algorithm: ORDER (T) begin if (T!=NULL) then begin ORDER (LPTR(T)) PRINT (DATA(T)) ORDER (RPTR(T)) end return end where LPTR: left pointer RPTR: right pointer T: given tree This above algorithm is used ... in in-order, in a recursive manner Traverse the tree in post-order in a recursive manner Do not Traverse the tree at all
Consider the following algorithm:ORDER (T) begin if (T!=NULL) then begin ORDER (LPTR(T)) PRINT (DATA(T)) ORDER (RPTR(T)) end return end where LPTR: left pointer RPTR: rig...
Bikram
385
views
Bikram
asked
Jan 16, 2017
GATE
tbb-mockgate-1
data-structures
tree
+
–
4
votes
2
answers
1238
Test by Bikram | Mock GATE | Test 1 | Question: 16
Hash a list of $3$ keys into hash table with $20$ locations. What will be the probability of the event $A$ in which hashing the three keys causes a collision? $0.123$ $0.145$ $0.800$ $0.750$
Hash a list of $3$ keys into hash table with $20$ locations. What will be the probability of the event $A$ in which hashing the three keys causes a collision?$0.123$$0.14...
Bikram
888
views
Bikram
asked
Jan 16, 2017
GATE
tbb-mockgate-1
data-structures
hashing
algorithms
+
–
0
votes
1
answer
1239
Say true or false?
preorder traversal of a tree resemble to the DFS traversal of graph?
preorder traversal of a tree resemble to the DFS traversal of graph?
S Ram
1.2k
views
S Ram
asked
Jan 15, 2017
Programming in C
data-structures
tree-traversal
+
–
1
votes
2
answers
1240
binary heap
Consider a binary min heap containing n elements and every node is having degree 2 ( i.e. full binary min heap tree). What is the probability of finding the largest element at the last level ? According to my understanding the largest element has to be a leaf and since leafs can be on two levels last and second last therefore the probability should be 1/2
Consider a binary min heap containing n elements and every node is having degree 2 ( i.e. full binary min heap tree). What is the probability of finding the largest eleme...
Pankaj Joshi
2.2k
views
Pankaj Joshi
asked
Jan 14, 2017
DS
data-structures
binary-heap
geeksforgeeks-test-series
+
–
1
votes
1
answer
1241
MadeEasy Subject Test: Programming & DS - Heap
How come the answer is 8 I think it shoulb be 4.
How come the answer is 8 I think it shoulb be 4.
harshit agarwal
724
views
harshit agarwal
asked
Jan 14, 2017
DS
made-easy-test-series
data-structures
binary-heap
+
–
2
votes
1
answer
1242
MadeEasy Subject Test: Programming & DS - Queues
# plz check ??? i missed something
# plz check ??? i missed something
Hradesh patel
483
views
Hradesh patel
asked
Jan 13, 2017
DS
made-easy-test-series
data-structures
queue
+
–
5
votes
2
answers
1243
Tree DFS
int func(Node root) { if(root == NULL) return 0; else if(root->left == NULL && root->right == NULL) return 2; else return(3 + func(root->left) + func(root->right)); } Above code is executed on the following rooted tree. What will be the output?
int func(Node root) { if(root == NULL) return 0; else if(root->left == NULL && root->right == NULL) return 2; else return(3 + func(root->left) + func(root->right)); }Abov...
dd
985
views
dd
asked
Jan 13, 2017
Programming in C
depth-first-search
algorithms
data-structures
binary-tree
+
–
0
votes
0
answers
1244
Stack
Consider a stack is implemented using an array. What is worst case time complexity of push operation? A) O(n) B) O(log n) C) O(n log n) D) O(1)
Consider a stack is implemented using an array. What is worst case time complexity of push operation?A) O(n)B) O(log n)C) O(n log n)D) O(1)
srestha
5.4k
views
srestha
asked
Jan 13, 2017
DS
stack
data-structures
+
–
0
votes
0
answers
1245
testbook
what will be differnece if we use c)option and d) option explain ??
what will be differnece if we use c)option and d) option explain ??
focus _GATE
319
views
focus _GATE
asked
Jan 13, 2017
DS
testbook-test-series
test-series
data-structures
+
–
6
votes
2
answers
1246
DS-CLL
Time complexity to insert a node in the end of circular linked list, if the pointer to the 1st node is given and number of nodes in list is N is A)O(1) B)O(log N) C)O(N) D)O(N log N)
Time complexity to insert a node in the end of circular linked list, if the pointer to the 1st node is given and number of nodes in list is NisA)O(1)B)O(log N)C)O(N)D)O(N...
srestha
3.0k
views
srestha
asked
Jan 12, 2017
DS
data-structures
time-complexity
algorithms
linked-list
+
–
2
votes
1
answer
1247
doubt
Arnabi
563
views
Arnabi
asked
Jan 12, 2017
Programming in C
data-structures
+
–
0
votes
1
answer
1248
General doubt on calculating the Time complexity for the given Insertion Sort Algorithm in the worst and average case
INSERTION-SORT (A, n) ⊳ A[1 . . n]for (j ← 2 to len(A) ){key ← A[ j];i ← j – 1 ; while (i 0 and A[i] key) { A[...
LavTheRawkstar
838
views
LavTheRawkstar
asked
Jan 12, 2017
Algorithms
algorithms
time-complexity
sorting
programming-in-c
data-structures
+
–
4
votes
1
answer
1249
Virtual Gate Test Series: Programming & DS - Binary Search Tree
What is the correct answer?
What is the correct answer?
Purple
731
views
Purple
asked
Jan 12, 2017
DS
data-structures
tree
binary-search-tree
virtual-gate-test-series
+
–
1
votes
0
answers
1250
MadeEasy Subject Test: Programming & DS - Binary Tree
here i have doubt what are the meaning of 4th if statement???
here i have doubt what are the meaning of 4th if statement???
Hradesh patel
366
views
Hradesh patel
asked
Jan 12, 2017
DS
made-easy-test-series
data-structures
binary-tree
+
–
4
votes
2
answers
1251
DS-BST
If preorder of a BST is passed as an argument to the above function. Function returns 1 if, a)All the leaf nodes of the tree are at same level b) All the nodes of the tree have atmost 1 child c) True is a complete binary tree, where the nodes at each level are completely filled d) None of these
If preorder of a BST is passed as an argument to the above function. Function returns 1 if,a)All the leaf nodes of the tree are at same levelb) All the nodes of the tree ...
srestha
946
views
srestha
asked
Jan 12, 2017
DS
data-structures
tree
+
–
3
votes
2
answers
1252
Binary Search tree
Consider an array with ‘n’ numbers, let “T” be time complexity for finding a number appeared maximum number of times in an array. Using Binary Search Tree data structure the T will be A. O(log n) B. O(n) C. O(n logn) D. O(n2)
Consider an array with ‘n’ numbers, let “T” be time complexity for finding a number appeared maximum number of times in an array. Using Binary Search Tree data st...
Nithish
2.1k
views
Nithish
asked
Jan 11, 2017
Programming in C
binary-search-tree
data-structures
time-complexity
+
–
0
votes
0
answers
1253
DS-Complexity2
1)Consider the AVL tree with n nodes. The best upper bound on the time required to insert n more elements in given AVL tree is O(na logb n). Then the value of a + 50b is ________. 2) https://gateoverflow.in/1776/gate2014-1_12 -------------- ... or BST. best upper bound= lowest upper bound should be worst case. Then GATE question complexity should be $\Theta (n log n)$ Plz explain
1)Consider the AVL tree with n nodes. The best upper bound on the time required to insert n more elements in given AVL tree is O(na logb n). Then the value of a + 50b is ...
srestha
304
views
srestha
asked
Jan 11, 2017
DS
data-structures
+
–
3
votes
3
answers
1254
Testbook Test Series: Programming & DS - Graphs
focus _GATE
758
views
focus _GATE
asked
Jan 11, 2017
Programming in C
testbook-test-series
test-series
data-structures
depth-first-search
graph-theory
+
–
3
votes
2
answers
1255
DS Complexity
You are given the pre-oder traversal T of a binary search tree on the n elements 1, 2, 3,...n. You have to determine the unique binary search tree that has T as its pre-oder traversal. What is the time complexity of the most efficient algorithm for doing this? (A)$\Theta (n^{2})$ (B)$\Theta (n log n)$ (C)$\Theta (log n)$ (D)$\Theta (n)$
You are given the pre-oder traversal T of a binary search tree on the n elements 1, 2, 3,...n. You have to determine the unique binary search tree that has T as its pre-o...
srestha
940
views
srestha
asked
Jan 10, 2017
DS
data-structures
+
–
4
votes
1
answer
1256
AVL Tree
What are we suppose to take? LR - 2 rotations. RL- 2 rotations. OR LR - 1 rotation. RL- 1 rotation. Kindly Solve and Verify the Total Numbers of Rotations Performed.
What are we suppose to take?LR - 2 rotations.RL- 2 rotations.ORLR - 1 rotation.RL- 1 rotation.Kindly Solve and Verify the Total Numbers of Rotations Performed.
Jason GATE
821
views
Jason GATE
asked
Jan 9, 2017
DS
avl-tree
data-structures
+
–
0
votes
2
answers
1257
MadeEasy Subject Test: Programming & DS - Hashing
True Or False.....? Explain...?
True Or False.....? Explain...?
Meghashyam Sujay
567
views
Meghashyam Sujay
asked
Jan 9, 2017
DS
made-easy-test-series
data-structures
hashing
+
–
1
votes
2
answers
1258
B + TREE DELETION
CAN SOMEONE PLZ EXPLAIN TO ME DELETION IN B+ TREES?? I AM NOT ABLE TO UNDERSTAND CLEARLY.
CAN SOMEONE PLZ EXPLAIN TO ME DELETION IN B+ TREES?? I AM NOT ABLE TO UNDERSTAND CLEARLY.
sushmita
817
views
sushmita
asked
Jan 8, 2017
Databases
b-tree
data-structures
databases
+
–
1
votes
0
answers
1259
MadeEasy Subject Test: Programming & DS - Binary Tree
Lucky sunda
234
views
Lucky sunda
asked
Jan 8, 2017
DS
made-easy-test-series
data-structures
binary-tree
+
–
1
votes
1
answer
1260
MadeEasy Subject Test: Programming & DS - Heap
It should be 5 according to me.Pleas explain if they are correct.
It should be 5 according to me.Pleas explain if they are correct.
Lucky sunda
634
views
Lucky sunda
asked
Jan 8, 2017
DS
made-easy-test-series
data-structures
binary-heap
+
–
Page:
« prev
1
...
37
38
39
40
41
42
43
44
45
46
47
...
60
next »
Email or Username
Show
Hide
Password
I forgot my password
Remember
Log in
Register