Under what condition the number of inversions in an array are maximum?

Q & ACategory: Data StructureUnder what condition the number of inversions in an array are maximum?
Admin Staff asked 4 years ago

Under what condition the number of inversions in an array are maximum?
a) when the array is sorted
b) when the array is reverse sorted
c) when the array is half sorted
d) depends on the given array

1 Answers
Admin Staff answered 4 years ago

b) when the array is reverse sorted