GATE CS 2024, set 2 · Question 35 · Algorithms · Numerical answer (NAT) · 1 mark · no negative marks
Let A be an array containing integer values. The distance of A is defined as the minimum number of elements in A that must be replaced with another integer so that the resulting array is sorted in non-decreasing order. The distance of the array [2, 5, 3, 1, 4, 2, 6] is ______
Answer
Answer 3
Answer from the official GATE CS 2024 answer key.
The step-by-step solution, where available, is part of GATE CS Pro. See what Pro includes