My Computer Forum Computer Science Forum

Go Back   My Computer Forum > Computer Science Forum > Algorithms

Algorithms Algorithms and Data Structures - Analysis, Graph, Search, String, Sorting, Merge, Compression, Optimization, Quantum


Reply
 
LinkBack Thread Tools Display Modes
December 14th, 2012, 03:30 PM   #1
 
Joined: Dec 2012
Posts: 1
Choose heap or bst

Hi.
I have a problem in my Algorithms and Data Structures course that I can not solve.
Anyone who can give me some guidance?

We have a set of numbers and we do lg(n) searchers and lg(n) lookups of the maximum over a time period.
We can choose between a heap and a binary search tree to maintain this set.
1.
If we are interested in minimizing the average total runtime over the time period.
What is the asymptotic upper bound on the total runtime for each structure and which one should we choose?
2.
If we are interested in the worst case, what is the asymptotic upper bound on the worst case runtime and which one
should we choose now?
Rebecka is offline  
 

My Computer Forum is free to register and we welcome everyone!

Reply

  My Computer Forum > Computer Science Forum > Algorithms

Tags
bst, choose, heap



Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Heap Sort Help david cool Algorithms 2 April 27th, 2008 02:35 AM





Copyright © 2018 My Computer Forum Forum. All rights reserved.