Code Question Option A Option B Option C Option D Answer
CS301 Which Of The Following Statement Concerning Heaps Is Not True? Traversing A Heap In Order Provides Access To The Data In Numeric Or Alphabetical Order Removing The Item At The Top Provides Immediate Access To The Key Value With Highest (Or Lowest) Priority Inserting An Item Is Always Done At The End Of The Array But Requires Maintaining The Heap Property A Heap May Be Stored In An Array A
CS301 Which Of The Following Statement Is Correct About Find(X) Operation A Find(X) On Element X Is Performed By Returning Exactly The Same Node That Is Found A Find(X) On Element X Is Performed By Returning The Root Of The Tree Containing X A Find(X) On Element X Is Performed By Returning The Whole Tree Itself Containing X A Find(X) On Element X Is Performed By Returning True B
CS301 Which Of The Following Statement Is Correct About Union? To Perform Union Of Two Sets We Merge The Two Trees By Making The Root Of One Tree Point To The Root Of The Other To Perform Union Of Two Sets We Merge The Two Trees By Making The Leaf Node Of One Tree Point To The Root Of The Other Perform Union Of Two Sets Merging Operation Of Trees In Not Required At All None Of The Given Options A
CS301 Which Of The Following Statement Is Correct? A Threaded Binary Tree Is A Binary Tree In Which Every Node That Does Not Have A Left Child Has A Thread (In Actual Sense A Link) To Its Inorder Successor A Threaded Binary Tree Is A Binary Tree In Which Every Node That Does Not Have A Right Child Has A Thread (In Actual Sense A Link) To Its Preoredr Successor A Threaded Binary Tree Is A Binary Tree In Which Every Node That Does Not Have A Right Child Has A Thread (In Actual Sense A Link) To Its Inorder Successor A Threaded Binary Tree Is A Binary Tree In Which Every Node That Does Not Have A Right Child Has A Thread (In Actual Sense A Link) To Its Postorder Successor C
CS301 Which Of The Following Statement Is Not Correct About Find Operation It Is Not A Requirement That A Find Operation Returns Any Specific Name Just That Finds On Two Elements Return The Same Answer If And Only If They Are In The Same Set One Idea Might Be To Use A Tree To Represent Each Set Since Each Element In A Tree Has The Same Root Thus The Root Can Be Used To Name The Set Initially Each Set Contains One Element Initially Each Set Contains One Element And It Does Not Make Sense To Make A Tree Of One Node Only B
CS301 Which Of The Following Statement Is Not Correct About Find Operation: It Is Not A Requirement That A Find Operation Returns Any Specific Name Just That Finds On Two Elements Return The Same Answer If And Only If They Are In The Same Set One Idea Might Be To Use A Tree To Represent Each Set Since Each Element In A Tree Has The Same Root Thus The Root Can Be Used To Name The Set Initially Each Set Contains One Element Initially Each Set Contains One Element And It Does Not Make Sense To Make A Tree Of One Node Only B
CS301 Which Of The Following Statement Is Not True About Threaded Binary Tree? Right Thread Of The Right-Most Node Points To The Dummy Node Left Thread Of The Left-Most Node Points To The Dummy Node The Left Pointer Of Dummy Node Points To The Root Node Of The Tree Left Thread Of The Right-Most Node Points To The Dummy Node D
CS301 Which Of The Following Statement Is True About Dummy Node Of Threaded Binary Tree? This Dummy Node Never Has A Value This Dummy Node Has Always Some Dummy Value This Dummy Node Has Either No Value Or Some Dummy Value This Dummy Node Has Always Some Integer Value C
CS301 Which Of The Following Statements Is Correct Property Of Binary Trees? A Binary Tree With N Internal Nodes Has N+1 Internal Links A Binary Tree With N External Nodes Has 2N Internal Nodes A Binary Tree With N Internal Nodes Has N+1 External Nodes None Of Above Statement Is A Property Of The Binary Tree C
CS301 Which Of The Following Tests In The Client Code Correctly Compares Two Class Objects Alpha And Beta? If (Alpha < Beta) If (Alpha.Lessthan(Beta)) If (Lessthan(Alpha Beta)) If (Lessthan(Alpha).Beta) B
CS301 Which Of The Given Option Is Not A Factor In Union By Size Maintain Sizes (Number Of Nodes) Of All Trees And During Union Make Smaller Tree The Subtree Of The Larger One Make The Larger Tree The Subtree Of The Smaller One Implementation: For Each Root Node I Instead Of Setting Parent[I] To -1 Set It To -K If Tree Rooted At I Has K Nodes C
CS301 Which Of The Given Option Is Not A Factor In Union By Size: Maintain Sizes (Number Of Nodes) Of All Trees And During Union Make Smaller Tree The Subtree Of The Larger One Make The Larger Tree The Subtree Of The Smaller One Implementation: For Each Root Node I Instead Of Setting Parent[I] To -1 Set It To -K If Tree Rooted At I Has K Nodes C
CS301 Which One Is A Self-Referential Data Type? Stack Queue Link List All Of These C
CS301 Which One Of The Following Algorithms Is Most Widely Used Due To Its Good Average Time Bubble Sort Insertion Sort Quick Sort Merge Sort C
CS301 Which One Of The Following Calling Methods Does Not Change The Original Value Of The Argument In The Calling Function? None Of The Given Options Call By Passing The Value Of The Argument Call By Passing Reference Of The Argument Call By Passing The Address Of The Argument B
CS301 Which One Of The Following Is Correct About Pointers? They Always Point To?Different Memory Locations They May Point To A Single?Memory Location The Address Of Two Pointer Variables Is Same None Of These B
CS301 Which One Of The Following Is Known As "Last-In First-Out" Or Lifo Data Structure? Linked List Stack Queue Tree B
CS301 Which One Of The Following Is Not An Example Of Equivalence Relation? Electrical Connectivity Set Of People <= Relation Set Of Pixels C
CS301 Which One Of The Following Is Not The Property Of Equivalence Relation Reflexive Symmetric Transitive Associative D
CS301 Which One Of The Following Is Not True Regarding The Skip List? Each List Si Contains The Special Keys + Infinity And - Infinity List S0 Contains The Keys Of S In Non-Decreasing Order Each List Is A Subsequence Of The Previous One List Sh Contains Only The N Special Keys D