I am doing an analysis of Selection Sort on an array of 1000 elements. The array is Almost In Order.
To the best of my knowledge, there is no technical meaning of the word "almost", so you use the English meaning of the word "almost". Presumably the person asking the question wants you to see what happens when all the elements are in their proper place except, say, the last two (or the first two, or two in the middle, or etc.)
I'd say it means it's more than a Little in order but less than Completely in order.
"I am probably the laziest programmer on the planet, a fact with which anyone who has ever seen my code will agree." - esbo, 11/15/2008
"the internet is a scary place to be thats why i dont use it much." - billet, 03/17/2010
"Almost sorted" means that the data has a high degree of sortedness.
Here are several methods of measuring sortedness:
Last edited by iMalc; 03-22-2009 at 02:33 AM.
Advice: Take only as directed - If symptoms persist, please see your debugger
Linus Torvalds: "But it clearly is the only right way. The fact that everybody else does it some other way only means that they are wrong"