sort & search

We sort things to create order. Information (such as in train timetables and telephone books) is much easier to find in sorted form. This is why computers also sort things and computer scientists need to know and develop fast and efficient sorting methods.

Cup game
In computer science, sorting can function like the cup system in sport: in the starting row, eight players pair off and compare their height (or some other criterion). The taller stands still, the shorter moves forward. This is repeated in the next rows. The shortest remains and moves to the first square of the finish row. Starting from the back, the remaining players move forward one row. They continue comparing and moving forward until all are in the finish row. Are they now all correctly sorted?

Log-in for i-fans


If you have previously visited the i-factory, you can log in here.