Question DSA-ARR-0055
MediumA sorted array of n elements must stay sorted after inserting a new value. What is the time complexity, even though the position is found by binary search?
- A.
O(1)
- B.
O(n)
- C.
Sign up free to see the answer and a step-by-step explanation.