...
Nielit Scentist-B [02-12-2018]
October 10, 2023
Database-Management-System
October 10, 2023
Nielit Scentist-B [02-12-2018]
October 10, 2023
Database-Management-System
October 10, 2023

Nielit Scentist-B [02-12-2018]

Question 14
___ is the worst case time complexity for all operations(i.e. Search,update and delete) in a general binary search tree
A
O(n)
B
O(nlogn)
C
O(logn) for search and insert, and O(n) for delete
D
None of these
Question 14 Explanation: 
→ Suppose the elements are not in sorted order, it will take O(n) time for worst case time complexity.
→ In question, they are not mentioned about elements are sorted or unsorted. So, worst case we have to consider unsorted elements.
→ All operations(i.e. Search,update and delete) will take O(n).
Correct Answer: A
Question 14 Explanation: 
→ Suppose the elements are not in sorted order, it will take O(n) time for worst case time complexity.
→ In question, they are not mentioned about elements are sorted or unsorted. So, worst case we have to consider unsorted elements.
→ All operations(i.e. Search,update and delete) will take O(n).
0 0 votes
Article Rating
Subscribe
Notify of
0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x
error: Alert: Content selection is disabled!!