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 binarysearch
0
votes
1
answer
1
Binary Search
Q)How to solve using recursion tree method T(n) = T(n/2) + c ; n > 1 T(n) = C ; n = 1
asked
Jun 10
in
Algorithms
by
Lakshman Patel RJIT
Loyal
(
7.7k
points)

74
views
algorithms
binarysearch
+2
votes
1
answer
2
Binary Search Question!
The average successful search time taken by binary search on a sorted array of 5 CONSECUTIVE integers starting with 1? My Answer is  2.2 Kindly tell me is it correct or not? NOTE: I have edited the question and changes are shown in highlighted text.
asked
Mar 13
in
Algorithms
by
iarnav
Loyal
(
7.3k
points)

308
views
algorithms
binarysearch
+1
vote
1
answer
3
Algorithms : Binary search vs ternary search
asked
Mar 8
in
Algorithms
by
rahul sharma 5
Boss
(
24.1k
points)

200
views
binarysearch
datastructure
algorithms
+3
votes
0
answers
4
Interesting question on SQL
Consider a database with three relation instances shown below. The primary keys for the Drivers and Cars relation are did and cid respectively and the records are stored in ascending order of these primary keys as given in the tables. No indexing is available in ... If Binary Search is used to locate a tuple in a relation using primary key, then what is the range of n?
asked
Jan 31
in
Databases
by
Balaji Jegan
Active
(
1.1k
points)

142
views
databases
sql
query
binarysearch
+3
votes
1
answer
5
ACE Test Series
asked
Jan 18
in
Algorithms
by
ankit_thawal
Active
(
2.1k
points)

136
views
binarysearch
+3
votes
1
answer
6
Binary Search
Suppose we have the following sorted list: [3, 5, 6, 8, 11, 12, 14, 15, 17, 18] and array data structure is used. We are using recursive binary search algorithm to search an element 8. Which of the following group of number correctly shown the sequence of comparison used to find element 8? (Assume array index starting with 0). a) 11,5,6,8 b) 12,6,11,8
asked
Dec 8, 2017
in
Algorithms
by
VS
Loyal
(
8.7k
points)

333
views
binarysearch
+4
votes
3
answers
7
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)

392
views
binarytree
binarysearch
binarysearchtree
+3
votes
1
answer
8
Modified Binary search
asked
Nov 23, 2017
in
Algorithms
by
saxena0612
Boss
(
11.4k
points)

250
views
binarysearch
algorithms
acetestseries
+6
votes
2
answers
9
Question on sorted array and time complexity
asked
Nov 22, 2017
in
Algorithms
by
Akash Mishra
Junior
(
999
points)

567
views
algorithms
sorting
timecomplexity
binarysearch
+2
votes
0
answers
10
Binary Search
In this given question I find all answers false because while implementing binary seach or tracing it for an example we need to follow same approach Right? if we are taking ceil for evaluation then it should be considered throughout and if we are ... should be traced.Therefore applying both operating individually I find none of the options matching. Correct Me If I am wrong here.
asked
Nov 16, 2017
in
Algorithms
by
saxena0612
Boss
(
11.4k
points)

142
views
binarysearch
algorithms
+3
votes
1
answer
11
Binary search on two mutually exclusive arrays.
asked
Nov 6, 2017
in
Algorithms
by
Aghori
Loyal
(
6k
points)

216
views
binarysearch
algorithms
datastructure
timecomplexity
+5
votes
2
answers
12
Selfdoubt
Which of the following is exact recurrence relation for binary search (in terms of number of comparisons) ? 1. T(n) = 2T(n/2) + 1 2. T(n) = 2T(n/2) + 2 Please specify relevant reasons.
asked
Aug 22, 2017
in
Algorithms
by
just_bhavana
Boss
(
11.9k
points)

428
views
binarysearch
+9
votes
3
answers
13
Modified Binary Search
Suppose the first step in binary search algorithm is changed to M = (9L+R)/10, we know that the complexity of binary search is log(n). What will be the complexity of modified search? a) log(n) b) n c) n$\log 9/10(n)$ d) 2nlog(n)
asked
Aug 16, 2017
in
DS
by
Chandramani Adil
(
179
points)

474
views
modifiedbinarysearch
binarysearch
+6
votes
4
answers
14
Binary search
How to get space complexity of binary search .. I am getting confusion in Space complexity = ip + extra (stack) And ip = nB ( why it is nB) ????? And extra = logn B So nB+ log n B = O(n) ...
asked
Aug 10, 2017
in
Algorithms
by
air1ankit
Active
(
3.3k
points)

527
views
algorithms
binarysearch
+5
votes
4
answers
15
Binary Search
I/p  Sorted array of n element O/p find any two elements a and b such that (a+b)>1000 if lenear search is possible then go to Binary Search and Find time complexity ..?
asked
Jun 28, 2017
in
Algorithms
by
Raushank2
Active
(
1.1k
points)

474
views
algorithms
binarysearch
timecomplexity
+4
votes
1
answer
16
Difference between finding Inorder Successor vs finding next using Inorder Traversal in BST
asked
Jun 25, 2017
in
Algorithms
by
rahulsangwn
(
325
points)

294
views
algorithms
binarytree
binarysearch
binarysearchtree
+7
votes
2
answers
17
Self doubt in Binary search Algo
The average successful search time taken by binary search on a sorted array of $10$ items? $2.6$ $2.7$ $2.8$ $2.9$ Answer is $2.9$ My doubt: But when I am using $log_2n$ for $n = 10$ it is not equal to $2.9$, and $log_210 = 3.3219$ ?
asked
Jun 6, 2017
in
Algorithms
by
Shubhanshu
Boss
(
15k
points)

779
views
algorithms
binarysearch
timecomplexity
+6
votes
3
answers
18
binary search
I/p  array of n element in which untill some postion all are integer and afterward all are star (*) O/p find the postion of 1st star (*) Hint  if lenear search is possible the go to BS Find time complexity ..?
asked
Mar 9, 2017
in
Algorithms
by
air1ankit
Active
(
3.3k
points)

517
views
algorithms
binarysearch
binarysearchtree
+1
vote
1
answer
19
Time complexity to compute the sum of k smallest element in the binary search tree??
asked
Feb 2, 2017
in
Programming
by
sushmita
Boss
(
13.4k
points)

524
views
binarysearch
binarysearchtree
+4
votes
2
answers
20
binary search
Consider an array ‘A’ with 2m elements. The elements in odd position are sorted in nonincreasing order that is A[1] >= A[3] >= A[5]......A[2m1] The elements in even position are sorted in nondecreasing order, that is A[2]<= A[4] <= A[6].....A[2m]. Which of the following method is recommended for finding if a given number is in array?
asked
Nov 10, 2016
in
Algorithms
by
vaishali jhalani
Loyal
(
5.8k
points)

502
views
binarysearch
algorithms
0
votes
1
answer
21
binary search
Stack space used in binary search resursive implementation.
asked
Nov 10, 2016
in
Algorithms
by
vaishali jhalani
Loyal
(
5.8k
points)

287
views
binarysearch
algorithms
+1
vote
1
answer
22
#Algorithm
Given a sorted array of distinct interger A[1...N] , you want to find out whether there is an index "i" for which A[i] =i . if this problem is solved using divide and conquer method,then find time complexity.
asked
Nov 4, 2016
in
Algorithms
by
papesh
Boss
(
25.7k
points)

382
views
binarysearch
algorithms
+2
votes
1
answer
23
binary tree
asked
Oct 26, 2016
in
Algorithms
by
Shubham Pandey 2
Loyal
(
6.8k
points)

215
views
datastructure
binarytree
binarysearch
+6
votes
2
answers
24
Gatebook exam
Consider the following exponential search algorithm(ES). The array of n elements have to be searched is divided in to logn parts. The ith part is from index to. to search an element search all the parts one by one from left to right using binary search algorithm. What is the worst case complexity of above searching algorithm?
asked
Aug 27, 2016
in
Programming
by
Sayan Das 1
(
337
points)

471
views
binarysearch
+2
votes
3
answers
25
Binary Search Tree
Suppose we do not have a parent pointer in the nodes of a search tree, only leftchild and rightchild. Which of the following operations can be computed in time $O(\log n)$ for a balanced search tree? 1 find, insert, delete, but not min, max, pred, succ 2 ... pred, succ 3 find, insert, delete, pred, succ but not min, max 4 All of find, insert, delete, min, max, pred, succ
asked
Aug 23, 2016
in
Algorithms
by
Debashish Deka
Veteran
(
56.6k
points)

855
views
binarysearch
algorithms
datastructure
bst
binarytree
+4
votes
3
answers
26
Binary Tree
What is the difference between Binary Tree and Almost complete Binary tree and complete Binary Tree and full Binary Tree and Binary search Tree and Balanaced Binary Search Tree. Diagram would be appriciated otherwaise write 23 basic difference .
asked
Jul 16, 2016
in
DS
by
Don't you worry
Active
(
1.5k
points)

499
views
binarytree
binarysearch
datastructure
+1
vote
1
answer
27
Which search sequence is not possible in binary search tree?
asked
Jul 12, 2016
in
Programming
by
sh!va
Boss
(
34.1k
points)

1.7k
views
algorithms
binarysearch
+2
votes
2
answers
28
Binary search
If the binary search algorithm determines that the scanned argument is in upper half of the array,which of the following statement will set the appropriate variable to the appropriate value. A) startsub= middlesub1; B) startsub=middlesub+1; C)stopsub=middlesub1; D)stopsub=middlesub+1;
asked
Jun 24, 2016
in
DS
by
vivekpinto07
(
377
points)

534
views
binarysearch
+6
votes
2
answers
29
ISRO201162
The average depth of a binary search tree is $O(n^{0.5})$ $O(n)$ $O(\log n)$ $O(n \log n)$
asked
Jun 23, 2016
in
DS
by
jothee
Veteran
(
98.5k
points)

1.9k
views
isro2011
datastructure
binarysearch
Page:
1
2
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
IISc CSA and CDCS written test and interview Experince
IIIT Hyderabad Interview Experience
My failure, Oh wait SUCCESS journey
ALGORITHMS CHECKLIST:
A Failure who got into IISc
Follow @csegate
Gatecse
Recent questions tagged binarysearch
Recent Blog Comments
Sir I didn't get an email for GO classroom, ...
any one with marks less than 125 selected?
Thank you @Arjun Sir, @NamitaAIR1, @Priyanka, ...
Your story is very inspiring for the boys like me ...
So you completed your Btech in 5 yrs? How could ...
36,194
questions
43,647
answers
124,091
comments
42,930
users