retagged by
249 views

1 Answer

Best answer
2 votes
2 votes
let ...original seuence is this....

5 9 3(index2) 4  2 6 3(index 6)....

after sorting..

2  3(index2) 3(index 6) 4 5 6 8...Stable....

2  3(index6) 3(index 2) 4 5 6 8...not...Stable....
selected by

Related questions

531
views
1 answers
5 votes
GO Classes asked Jun 13, 2022
531 views
If we have an array of size $\mathrm{N}$ with only $3$ different values for its elements, what is the probability that the first partition results in a completely sorted array? Assume ... $1 / 3$1 / 4$2 / 3$