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

I forgot my password
All Activity
Questions
Unanswered
Tags
Subjects
Users
Ask
Previous
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 binarysearchtree
0
votes
2
answers
1
Binary Tree Array Implementation
What must be the ideal size of array if the height of tree is ālā? a) 2l1 b) l1 c) l d) 2l
asked
1 day
ago
in
Programming
by
pradeepchaudhary
(
231
points)

19
views
binarysearchtree
binarytree
datastructure
0
votes
1
answer
2
Binary Search Tree
8. What are the worst case and average case complexities of a binary search tree? a) O(n), O(n) b) O(logn), O(logn) c) O(logn), O(n) d) O(n), O(logn)
asked
1 day
ago
in
Programming
by
pradeepchaudhary
(
231
points)

19
views
datastructure
binarysearchtree
bst
binarytree
algorithms
+1
vote
0
answers
3
Binary Search Tree
1) How many ways we can traverse 1,2,3,4 in BST? 2) How many ways we can insert 1,2,3,4 in BST? ______________________________________________________________________ How both are different in calculation of BST?Why they are use different formula?
asked
2 days
ago
in
DS
by
srestha
Veteran
(
92.2k
points)

34
views
datastructure
binarysearchtree
bst
+2
votes
1
answer
4
Binary Search Tree
Number of ways we can insert 5,6,9,10 in the nodes of BST, such that height of BST is either 2 or 3?
asked
3 days
ago
in
DS
by
srestha
Veteran
(
92.2k
points)

124
views
datastructure
bst
binarysearchtree
0
votes
1
answer
5
Program of Binary Tree
Why not this code not printing 10? (It is just a binary tree with one node i.e. root. And value of root is 10) #include <stdio.h> #include<stdlib.h> struct BinaryTree *root=NULL; struct BinaryTree{ int data; struct BinaryTree *left; struct BinaryTree * ... root=node(data1); return root; } } int main() { insert(root,10); printf("%d",*root); return 0; }
asked
6 days
ago
in
DS
by
srestha
Veteran
(
92.2k
points)

46
views
datastructure
binarytree
binarysearchtree
+2
votes
2
answers
6
self doutbt
How to Construct Full Binary Tree from given preorder and postorder? Thank you.
asked
Jul 16
in
DS
by
Vegeta
(
193
points)

51
views
binarytree
binarysearchtree
treetraversal
0
votes
2
answers
7
Binary search tree preorder
someone please explain this question A binary search tree contains the values 1, 2, 3, 4, 5, 6, 7, 8. The tree is traversed in preorder and the values are printed out. Which of the following sequences is a valid output? how the option D is correct? A 53124786 B 53126487 C 53241678 D 53124768
asked
Jul 5
in
Study Resources
by
amber12
(
47
points)

53
views
binarysearchtree
treetraversal
bst
0
votes
1
answer
8
Binary Tree
Can a binary tree or BST can be constructed with dynamic programming? Can it be constructed through greedy method? Plz give some algorithm and explain
asked
Jun 30
in
Algorithms
by
srestha
Veteran
(
92.2k
points)

56
views
binarytree
binarysearchtree
algorithms
+1
vote
2
answers
9
Gradup topicwise question
Consider the vales of bst $11,22,33,44,55,66,77,88$. Which of the following is a valid sequence of preorder traversal? $55,33,11,22,44,77,66,88$ $55,33,22,44,11,66,77,88$ $55,33,11,44,22,66,77,88$ $55,33,11,44,22,66,77,88$ Given answer is option A But how?
asked
May 22
in
Programming
by
Sona Barman
Active
(
1.2k
points)

82
views
datastructure
binarysearchtree
0
votes
0
answers
10
Balanced tree vs Complete binary tree
1. Please Verify this: Assuming pointer to node which need to be deleted given Balanced Binary Tree insertion = O(logn), deletion= O(logn) Complete Tree insertion = O(1), deletion= O(1) Assuming pointer to node which need to be deleted not given ... better than a complete binary tree for sorting a set S of n elements . Is it true if it is then reason please ?
asked
May 6
in
Algorithms
by
Na462
Active
(
4.6k
points)

77
views
datastructure
binarysearchtree
0
votes
4
answers
11
trees
Given a preorder, postorder and inorder traversal of a tree, is it always possible to obtain a tree that satisfies each of the three conditions? Or is it possible to not obtain a tree at all?
asked
Feb 19
in
DS
by
Parimal Paritosh
(
219
points)

172
views
binarytree
algorithms
spanningtree
binarysearchtree
+1
vote
1
answer
12
Binary Tree
I have doubt when its asked to know number of labelled and unlabelled binary tree : For labelled = (On basis of labelling) T(n) = 2nCn/(n+1) * n! For unlabelled = (On Basis of Geometric Sturucture) T(n) = (2n)Cn/n+1 Right? What if its Asked for BST what will be the answer in both the above cases and Why?
asked
Feb 17
in
Algorithms
by
Na462
Active
(
4.6k
points)

109
views
datastructure
binarytree
binarysearchtree
algorithms
+6
votes
1
answer
13
Binary Search Tree
Q1. How many binary search trees possible with $11$ distinct key? Q2. How many binary search trees possible with $11$ unlabelled nodes? Q3. How many binary search trees possible with $11$ labelled nodes? Q4. How many binary trees possible with $11$ ... Q5. How many binary trees possible with $11$ unlabelled nodes? Q6. How many binary trees possible with $11$ labelled nodes?
asked
Feb 2
in
DS
by
Lakshman Patel RJIT
Loyal
(
8k
points)

315
views
datastructure
binarysearchtree
binarytree
+4
votes
1
answer
14
Balanced binary search tree
A balanced binary search tree of n nodes,the number of steps needed to find and remove the 9th largest element in the worst case? (Please mention the algorithm followed)
asked
Jan 15
in
Algorithms
by
VS
Loyal
(
8.9k
points)

144
views
algorithms
datastructure
binarysearchtree
0
votes
1
answer
15
DS BINARY TREE
Consider a binary tree T that has 100 leaf nodes. Then the number of INTERNAL nodes in T that have exactly two children are ______.
asked
Jan 7
in
DS
by
iarnav
Loyal
(
7.9k
points)

172
views
datastructure
binarytree
binarysearchtree
+1
vote
1
answer
16
Self doubt B tree B+tree
To insert key into level L B/B+ tree maximum new nodes require to create?? And how?
asked
Jan 6
in
Databases
by
Anshul Shankar
Active
(
1.1k
points)

67
views
databases
btree
binarysearchtree
0
votes
0
answers
17
Test Series
Can someone explain how to solve such a problem?
asked
Dec 26, 2017
in
DS
by
Kalpataru Bose
(
367
points)

60
views
algorithms
datastructure
binarysearchtree
madeeasytestseries
0
votes
1
answer
18
Programming and Data Structures
asked
Dec 21, 2017
in
DS
by
ashish pal
Active
(
1.1k
points)

121
views
datastructure
binarysearchtree
acetestseries
0
votes
1
answer
19
Test series zeal
Given an initially empty Binary search tree how many different order of insertion order A,B,C,D,E,F,G that returns minimum height tree?
asked
Dec 18, 2017
in
DS
by
Anish Palan
(
11
points)

67
views
binarysearchtree
datastructure
zeal
test
series
+3
votes
2
answers
20
ISRODEC201751
Suppose the numbers $7,5,1,8,3,6,0,9,4,2$ are inserted in that order into an initially empty binary search tree.The binary search tree uses the reversal ordering on natural numbers i.e. $9$ is assumed to be smallest and $0$ is assumed to be largest. The $in$$order$ traversal of the resultant binary search tree ... 7$ $0,1,2,3,4,5,6,7,8,9$ $0,2,4,3,1,6,5,9,8,7$ $9,8,7,6,5,4,3,2,1,0$
asked
Dec 17, 2017
in
DS
by
gatecse
Boss
(
18.1k
points)

561
views
isrodec2017
binarysearchtree
+1
vote
1
answer
21
ace test
The number of ways we can insert 11, 12, 13, 14, 15, 16, 17 in empty binary search tree such that resulting tree has the height of 6 = ___________ [height of a tree with single node is 0.]
asked
Dec 10, 2017
in
Programming
by
Mr_22B
Active
(
1.1k
points)

81
views
binarysearchtree
permutationsandcombinations
+4
votes
3
answers
22
Number of binary search trees
How many different binary search trees can be constructed using six distinct keys? 256 128 132 264
asked
Nov 27, 2017
in
DS
by
Parshu gate
Active
(
4.9k
points)

435
views
binarytree
binarysearch
binarysearchtree
0
votes
2
answers
23
data strucure
A search was performed on some binary search tree. Which of the following is a valid search sequence? (A) 1, 11, 111, 98, 58, 78, 90, 48, 88 (B) 333, 33, 53, 93, 63, 90, 70, 88 (C) 8, 888, 18, 98, 38, 78, 90, 48, 88 (D) 555, 5, 55, 95, 45, 65, 75, 88
asked
Nov 9, 2017
in
Programming
by
Kaluti
Loyal
(
5.5k
points)

49
views
binary
binarysearchtree
0
votes
2
answers
24
UGCNETNov2017II22
The following numbers are inserted into an empty binary search tree in the given order: 10, 1, 3, 5, 15, 12, 16. What is the height of the binary search tree? A. 3 B. 4 C. 5 D. 6
asked
Nov 9, 2017
in
DS
by
Devwritt
Active
(
3.1k
points)

476
views
ugcnetnov2017ii
datastructure
binarysearchtree
0
votes
1
answer
25
Binary Tree construction
Given the preorder/postorder and inorder traversal of a binary tree, we can always construct a unique binary tree (I think so, correct me if I am wrong) Construct a binary tree with the nodes A, B, C such that its preorder traversal is ABC and its inorder traversal is CAB.
asked
Nov 8, 2017
in
DS
by
humblefool
Junior
(
947
points)

272
views
datastructure
algorithms
bst
binarytree
treetraversal
binarysearchtree
+2
votes
0
answers
26
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 that order. Let P is the probability that 3rd element on the search path beginning from the root is either 3 or 8.and N are the number of different order possible in which given nodes can be traversed before finding node with value 5 .Find (N/10)+P
asked
Nov 7, 2017
in
Programming
by
set2018
Loyal
(
7.8k
points)

133
views
binarysearchtree
datastructure
+4
votes
0
answers
27
tifr2010b26 gate2014339
I don't seem to get the difference in both the questions. Finding L (or a) will take O(log n) comparisons which is fine. But now to search all elements between L and H (or a and b), weather it will take O(log n) time or constant time ? In the ... question, it is unclear. So how much time does it take ro search all elements between L and H (or a and b). ? Kindly explain.
asked
Oct 26, 2017
in
DS
by
rishi71662data4
Active
(
2.3k
points)

129
views
binarysearchtree
datastructure
+1
vote
2
answers
28
Why given C code of Binary Search Tree is errorneous.
asked
Aug 23, 2017
in
Programming
by
Aghori
Loyal
(
6.1k
points)

135
views
binarysearchtree
programminginc
datastructure
0
votes
1
answer
29
BST doubt
if the value is less the root then it will goto left subtree & if the value is greater than root then it will go right. 1)what we do if value = root??(for multiple time same values) 2) duplicate values are allowed??
asked
Aug 21, 2017
in
DS
by
Hira Thakur
Boss
(
12.7k
points)

54
views
binarysearchtree
+1
vote
2
answers
30
traversal
how to make binary search tree from the given post order traversal 1,2,3,4................n if no inorder or preorder is mentioned?????????//
asked
Jul 10, 2017
in
Algorithms
by
akankshadewangan24
Active
(
4k
points)

60
views
binarysearchtree
Page:
1
2
3
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
Anxiety
Nielit 2018
Donation (Kerala Flood)
Schedule for GATE 2019
GATE 2019 official website
Follow @csegate
Gatecse
Recent questions tagged binarysearchtree
Recent Blog Comments
Thanx Mk utkarsh and nikhil bro ... i really ...
Firstly I am not topper. or ranker.
but ...
If you are not able to understand the concept of ...
done:)
Thanx man ... i really appreciate it ...
38,203
questions
45,706
answers
132,821
comments
49,756
users