URI:
   DIR Return Create A Forum - Home
       ---------------------------------------------------------
       techsuns
  HTML https://techsuns.createaforum.com
       ---------------------------------------------------------
       *****************************************************
   DIR Return to: Puzzles && Algorithms
       *****************************************************
       #Post#: 68--------------------------------------------------
       Modified Binary Search Tree.
       By: ravu Date: September 1, 2012, 1:20 am
       ---------------------------------------------------------
       You wish to create a modified binary search tree which most
       efficiently supports all of the following operations:
       insert(x): inserts a node into the tree
       find(x): checks if the tree contains a node x
       rank(i): finds the node with the ith smallest value
       
       Which of the following potential modifications, by itself, would
       enable a binary tree to support rank(i) most efficiently
       (without significantly impacting the efficiency of the other
       operations)? Select all that apply.
       A. Each node X maintains a variable  rank that represents this
       node's rank.
       B. Each node tracks the number of its children.
       C. Each node has a pointer to its parent.
       D. Each node knows its rank (ie, how many nodes are less than
       it) within its own subtree.
       E. Keep the tree as is, but also create a hash table that maps
       from an integer to the node with that rank.
       This is from
       Link for the problems -
  HTML http://www.proprofs.com/quiz-school/story.php?title=fundamentals-for-coding-interviews
       #Post#: 170--------------------------------------------------
       Re: Modified Binary Search Tree.
       By: Kaliuday Balleda Date: November 20, 2012, 12:00 am
       ---------------------------------------------------------
       A & E can apply! wats the ans techie?
       *****************************************************