Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p><a href="http://en.wikipedia.org/wiki/B-tree" rel="noreferrer">B-trees</a> are in databases.</p> <p><a href="http://en.wikipedia.org/wiki/R-tree" rel="noreferrer">R-trees</a> are for geographic searches (e.g. if I have 10000 shapes each with a bounding box scattered around a 2-D plane, which of these shapes intersect an arbitrary bounding box B?)</p> <p><a href="http://en.wikipedia.org/wiki/Deque" rel="noreferrer">deques</a> of the form in the <a href="http://www.sgi.com/tech/stl/Deque.html" rel="noreferrer">C++ STL</a> are growable vectors (more memory-efficient than linked lists, and constant-time to "peek" arbitrary elements in the middle). As far as I can remember, I've never used the deque to its full extent (insert/delete from both ends) but it's general enough that you can use it as a stack (insert/delete from one end) or queue (insert to one end, delete from the other) and also have high-performance access to view arbitrary elements in the middle.</p> <p>I've just finished reading <a href="http://books.google.com/books?id=3keGb40PWJsC" rel="noreferrer">Java Generics and Collections</a> -- the "generics" part hurts my head, but the collections part was useful &amp; they point out some of the differences between skip lists and trees (both can implement maps/sets): skip lists give you built-in constant time iteration from one element to the next (trees are O(log n) ) and are much simpler for implementing lock-free algorithms in multithreaded situations.</p> <p>Priority queues are used for scheduling among other things (here's a <a href="http://users.csc.tntech.edu/~algviz/priority_queue/applications.php" rel="noreferrer">webpage</a> that briefly discusses application); heaps are usually used to implement them. I've also found that the heapsort (for me at least) is the easiest of the O(n log n) sorts to understand and implement.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload