> What does the OP actually want?
I started writing another fake defrag program to entertain myself in a
little downtime at work. The FAT-styled "drive" is just a Python list
of integers where each element points to the the next "block" of the
fictitious "file", with the last element of any given
> There is a name for this: it is called a RANK TABLE.
Handy. That should help.
Alan
___
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor
On 12/05/2013 12:02 PM, Alan Gauld wrote:
But the OP didn't ask for the final transform he asked for the list of
transforms that got from A to B. That means all of the intermediate steps. At
least that's how I read his statement "list-of-transforms
that got me from before to after"
I did not re
On 12/05/2013 11:52 AM, Steven D'Aprano wrote:
There is a name for this: it is called a RANK TABLE. In the example
given:
values = [3, 1, 2, 5, 4]
the rank table gives the rank of each element, that is, the position
they would get after sorting. In this case, the rank table is not
terribly exci
On 05/12/13 10:52, Steven D'Aprano wrote:
On Thu, Dec 05, 2013 at 09:55:27AM +, Alan Gauld wrote:
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?
No.
The reason being that it depends on the s
On Wed, Dec 04, 2013 at 10:56:32PM -0500, R. Alan Monroe wrote:
> 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 a
On Thu, Dec 05, 2013 at 09:55:27AM +, Alan Gauld wrote:
> On 05/12/13 03:56, R. Alan Monroe wrote:
> >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
>
On 05/12/13 03:56, R. Alan Monroe wrote:
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?
No.
The reason being that i
I believe you're asking for the term "Cycle notation".
http://en.wikipedia.org/wiki/Cycle_notation
On Wed, Dec 4, 2013 at 7:56 PM, R. Alan Monroe wrote:
> 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 the
On Wednesday 2013 December 04 19:56, R. Alan Monroe wrote:
> This seems like the kind of thing that probably exists, but there
> isn't a simple googlable term for searching it out conveniently.
Try "sorting algorithm".
--
Yonder nor sorghum stenches shut ladle gulls stopper torque wet
strainers
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
11 matches
Mail list logo