Given two lists, before and after a sort:
         0 1 2 3 4
         ---------
before:  3 1 2 5 4
after:   1 2 3 4 5

Is there a well-known algorithm that can give me the
list-of-transforms that got me from before to after?
e.g.:

first-to-zeroth,
zeroth-to-second,
second-to-first

fourth-to-third
third-to-fourth

This seems like the kind of thing that probably exists, but there
isn't a simple googlable term for searching it out conveniently.

Alan

_______________________________________________
Tutor maillist  -  Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor

Reply via email to