I suspect I am missing something very obvious, in which case could some
kind soul put me straight?
I have the following code
col := OrderedCollection new.
(1 to: 9) permutationsDo: [ :each | col add: (each )].
I thought this would give me a collection containing all the permutations.
However, what actually happens is that each of the arrays has been
'magically' sorted back into numerical order. If I change the code to read
col := OrderedCollection new.
(1 to: 9) permutationsDo: [ :each | col add: (each asOrderedCollection )].
Then the permutations are retained. Is this how it is supposed to work?
Or, am I doing something wrong?
Cheers
Andy