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

I forgot my password
Activity
Questions
Unanswered
Tags
Subjects
Users
Ask
Prev
Blogs
New Blog
Exams
Recent questions tagged heap
+5
votes
2
answers
1
Min Heap
In a minheap, the next largest element of a particular element can be found in ___ time. A) O(1) B) O(log n) C) O(n)
asked
Oct 31, 2017
in
Algorithms
by
Shivam Chauhan

813
views
heap
algorithms
binaryheap
timecomplexity
0
votes
0
answers
2
Data Structure: Find 7th smallest element in Min heap
In a binary min heap with n elements, the 7th smallest element can be found in _____ ? Answer given is O(logn) and solution: Delete the 1st smallest element O(logn) Delete the 2nd smallest element O(logn) .... ... this solution the data arrangement of the heap will be changed after performing these operation. any better solution than this???
asked
Oct 18, 2017
in
Programming
by
Shubhanshu

557
views
heap
binaryheap
timecomplexity
algorithms
0
votes
2
answers
3
UGCNETdec2008ii33
In a heap, every element is ___________ of all the elements in the subtree. maximum minimum sum product
asked
Sep 26, 2017
in
DS
by
rishu_darkshadow

344
views
ugcnetdec2008ii
datastructures
heap
+1
vote
1
answer
4
MAXHEAP increase key procedure
In the max heap Increase key procedure IncreaseKey(int pos, int newValue) { heap[pos] = newValue; while(left(pos) < heap.Length) { int smallest = left(pos); if(heap[right(pos)] < heap[left(pos)]) smallest = right(pos); if(heap[ ... property is violated at a node x, we dont call MAXHEAPIFY procedure to mend the Maxheap property, What is the reason behind it?
asked
Sep 15, 2017
in
Algorithms
by
vivek9837

408
views
algorithms
heap
0
votes
1
answer
5
How does memory layout of a program depend on address binding technique?
I have learned that with runtime address binding, the program can be allocated frames in the physical memory noncontiguously. Also, as described here and here, every segment of the program in the logical address space is ... placed together with the rest of the segments or separately just as in the case of runtime binding ?
asked
Mar 28, 2017
in
Operating System
by
Aman Vats

650
views
operatingsystem
memorymanagement
heap
stack
compilerdesign
virtualmemory
+6
votes
1
answer
6
Gate Practice Question
A binary minheap contains keys 1,2,3,4.....2047,2048 What is smallest key that can be at leaf node.??
asked
Feb 4, 2017
in
Algorithms
by
Ravi_1511

330
views
heap
+2
votes
0
answers
7
Min heap
how to solve this please explain procedure...
asked
Feb 1, 2017
in
Programming
by
S Ram

283
views
heap
testseries
+4
votes
1
answer
8
Time to build a heap
If you are given a sorted list with n elements in ascending order. Then what will be the Time complexity to build a Min heap from the given array?
asked
Jan 18, 2017
in
Algorithms
by
Gaurab Ghosh

439
views
algorithms
heap
timecomplexity
+1
vote
2
answers
9
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 elemenyt has to be a leaf and since leafs can be on two levels last and second last therefore the probability should be 1/2
asked
Jan 15, 2017
in
Algorithms
by
Pankaj Joshi

335
views
heap
binaryheap
algorithms
geekmock2017
+1
vote
1
answer
10
MadeEasy Subject Test: Programming & DS  Heap
How come the answer is 8 I think it shoulb be 4.
asked
Jan 15, 2017
in
DS
by
harshit agarwal

254
views
madeeasytestseries
datastructures
heap
+1
vote
0
answers
11
How to convert BST to max/min heap inplace ?
Please explain using images how to convert BST into max/min heap inplace . Please explain the complexity of doing so.
asked
Jan 10, 2017
in
Algorithms
by
Anjana Babu

738
views
algorithms
heap
0
votes
1
answer
12
MadeEasy Subject Test: Programming & DS  Heap
It should be 5 according to me.Pleas explain if they are correct.
asked
Jan 8, 2017
in
DS
by
Lucky sunda

167
views
madeeasytestseries
datastructures
heap
+26
votes
4
answers
13
min heap
The number of binary min. heaps that can be formed from a set of 7 distinct integers is _________?
asked
Jan 8, 2017
in
DS
by
Jithin Jayan

6.3k
views
algorithms
heap
combinatory
+14
votes
7
answers
14
Heap..
1)The number of min heap trees are possible with 15 elements such that every leaf node must be greater than all nonleaf nodes of the tree are ________.  2)The number of min heap trees are possible with 15 elements_________________
asked
Jan 4, 2017
in
Programming
by
srestha

1.6k
views
heap
+7
votes
2
answers
15
Max Heap
The number of ways , in which numbers 1,2,3,4,5 can be inserted into binary heap,such that resultant binary heap is max heap ? given ans :8
asked
Dec 9, 2016
in
Programming
by
minal

1.6k
views
heap
binaryheap
algorithms
+5
votes
2
answers
16
MadeEasy Test Series: Programming & DS  Heap
The number of min heap trees are possible with 15 elements such that every leaf node must be greater than all nonleaf nodes of the tree are ________.
asked
Dec 6, 2016
in
DS
by
Vishal Goyal

300
views
madeeasytestseries
datastructures
heap
+2
votes
2
answers
17
MadeEasy Test Series: Algorithms  Heap
Consider M1 and M2 be two complete binary tree which satisfy maxheap property, each of size ‘n’. What is the time complexity to combine both M1 and M2 such that combine tree will be min heap tree? O (n log n) O (n) O (n2) O (n2 log n)
asked
Dec 6, 2016
in
DS
by
Vishal Goyal

422
views
madeeasytestseries
datastructures
heap
timecomplexity
0
votes
1
answer
18
Self Made
Suppose we are given a set of elements to be inserted in a Max Heap. What is the approach to follow from the following? 1.Insert an element, apply HEAPIFY, insert the next element, again apply HEAPIFY, and so on. 2. Insert all the elements and once done, apply BUILDMAXHEAP. What is the correct approach?
asked
Dec 3, 2016
in
DS
by
Samujjal Das

79
views
heap
+16
votes
1
answer
19
GATE200677
Statement for Linked Answer Questions 76 & 77: A $3$ary max heap is like a binary max heap, but instead of $2$ children, nodes have $3$ children. A $3$ary heap can be represented by an array as follows: The root is stored in the first location, $a[0]$, nodes in the next level, from left to right, is ... $10, 9, 4, 5, 7, 6, 8, 2, 1, 3$ $10, 8, 6, 9, 7, 2, 3, 4, 1, 5$
asked
Nov 28, 2016
in
DS
by
Arjun

1.9k
views
gate2006
datastructures
heap
normal
+7
votes
1
answer
20
GATE19902viii
Match the pairs in the following questions: ...
asked
Nov 19, 2016
in
DS
by
makhdoom ghaya

1.1k
views
gate1990
matchthefollowing
datastructures
heap
+7
votes
2
answers
21
Space complexity of heap sort
Why space complexity of heapsort is O(1)....and why not O(logn)..because of space required by recursion calls which is equivalent to height of the tree...where am i getting wrong plz help...
asked
Nov 8, 2016
in
Algorithms
by
vineet.ildm

1.5k
views
algorithms
timecomplexity
spacecomplexity
sorting
heap
+4
votes
2
answers
22
Heaps
asked
Oct 26, 2016
in
Algorithms
by
jenny101

564
views
heap
algorithms
datastructures
+4
votes
1
answer
23
Max heap
A level of a max heap (containing 100 nos) is choosen randomly, on its selection, a node from the same level is choosen randomly. What is the probability that it is the 36th smallest element
asked
Oct 7, 2016
in
Algorithms
by
vivek9837

485
views
heap
algorithms
probability
+3
votes
1
answer
24
Binary Max Heap
In a binary max heap containing n numbers, the smallest element can be found in time?
asked
Sep 13, 2016
in
DS
by
Hardik Vagadia

495
views
binaryheap
heap
+6
votes
3
answers
25
7th smallest element in a MinHeap
In a minheap with n elements 1). The 7th smallest element can be found in time, if duplicates are allowed ? 2). The 7th distinct smallest element can be found in time, If duplicates are allowed ?
asked
Sep 4, 2016
in
Algorithms
by
Kapil

1.6k
views
algorithms
heap
binaryheap
sorting
timecomplexity
+1
vote
2
answers
26
UGCNETJune2011II: 25
When the priority queue is represented by max heap, the insertion and deletion of an element can be performed in (queue containing $n$ elements) $\theta(n)$ and $\theta(1)$ respectively $\theta(n)$ and $\theta(n)$ respectively $\theta(1)$ and $\theta(1)$ respectively None of the above
asked
Aug 25, 2016
in
Others
by
makhdoom ghaya

940
views
ugcnetjune2011ii
datastructures
queue
heap
+3
votes
2
answers
27
UGCNETJune2015III: 36
The number of nodes in height h in any nelement heap is $h$ $z^h$ ceil $\biggl(\frac{n}{z^h} \biggr)$ ceil $\biggl(\frac{n}{z^{h+1}} \biggr)$
asked
Aug 1, 2016
in
DS
by
jothee

715
views
ugcnetjune2015iii
datastructures
heap
+1
vote
1
answer
28
heap sort
The number of elements that can be sorted in time using heap sort ?
asked
Jul 30, 2016
in
Algorithms
by
reena_kandari

477
views
algorithms
timecomplexity
sorting
heapsort
heap
Page:
« prev
1
2
3
4
5
6
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
Interview Experience for MS(R)IIT Delhi (School of Information Technology)
How am I preparing
PGEE 2020 (CSE) Experience
IIT Tirupati MS Interview 2020
IIT Bombay Mtech RA  interview experience (2020)
Subjects
All categories
General Aptitude
(2k)
Engineering Mathematics
(8.2k)
Digital Logic
(2.9k)
Programming and DS
(5k)
Algorithms
(4.4k)
Theory of Computation
(6.2k)
Compiler Design
(2.2k)
Operating System
(4.6k)
Databases
(4.2k)
CO and Architecture
(3.4k)
Computer Networks
(4.2k)
Non GATE
(1.2k)
Others
(1.5k)
Admissions
(595)
Exam Queries
(562)
Tier 1 Placement Questions
(23)
Job Queries
(71)
Projects
(19)
Unknown Category
(1k)
Recent questions tagged heap
Recent Blog Comments
After getting so many mails from you...
Refund will be given for such cases if applied...
@sreejit007 they don't publish any cutoff or...
@ranjanabhi Can you please elaborate what did...
ISI 2019 : Aarushi Aiyyar's answer to How do...
Network Sites
GO Mechanical
GO Electrical
GO Electronics
GO Civil
CSE Doubts
52,345
questions
60,483
answers
201,810
comments
95,288
users