1 Inorder tniersal of binarysearch trw will produce A-untd o 2 qusae data struct
ID: 3721767 • Letter: 1
Question
1 Inorder tniersal of binarysearch trw will produce A-untd o 2 qusae data structure works on C-FIL Show A 3 Which of the following ian exampls of dynamic C-Dikslra Shor Path 4- What is not true about insertion sort? A Exabils the worst case performance wha the intial arnay is B-Worsl case and average case performa is Of C-Can be compared to the way a Cärd playärarranges h d D Noi of the above Q5- Which the following is exampls of in place B Merge Sort Show A 6 Tims ruquired to merge two sortd lists of size m -Which of the following uses memoization? C Dynat pro?ramming approach D Noi of the aboveExplanation / Answer
1)c
In order traversal gives node in sorted order it start from left to root to right subtree
2)b
Queue Data structure work on first in first out that is FIFO
which comes it will be served first also.
3)d
given all example used dynamic programming approach. all algorithms for solving these need t store the previous result in order tp
solve next.
4)d
5)c
Insertion sort take only 0(1) extra space for swapping only
6)b
its require only O(m+n) time to merge the list as it is already sorted.Next element to be used in each array, compare both values before inserting them in the new array. There are exactly n+m comparisons
7)c
dynamic programming approach can be used memorization or tabulation depends on needs.
memorization help to speedup the computation as it store the result in cache
//Please do let me know if u have any concern...
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.