Algorithms

  1) Suppose you could eliminate 2^n * 2^n permutations from consideration in sorting using a comparison-based sort. How would this affect your running time or number of comparisons you’d have to make in sorting? 2) –A) Create an NFA to accept any string with T-o-m in it and reject all others –B) Create a DFA to accept any string with T-o-m in it and reject all others 3) Quicksort could be more efficient that some other sorts as it could work better with Cache Memory in a processor. Explain what that means 4) Why is the Hashtable the ultimate data structure? 5) Find another valid coloring of the attached Red-Black Tree