Still trying to sort an array...
Posted: Sun Jun 29, 2008 11:43 pm
Edit: After making a simple card with
some reporting of results I find that
using the arrays below gets the end
result I was looking for.
So the question now is the interpretation
of the array which still seems obscure to me.
But I suppose I should be satisfied with a result.
-------------------------------------------------------
I have an array....
[1] 22
[2] 88
[3] 78
[4] 80
[5] 102
[6] 96
[7] 77
[8] 122
[9] 114
[10] 118
[11] 169
[12] 159
[13] 158
[14] 105
[15] 76
[16] 52
[17] 81
[18] 52
[19] 132
[20] 82
[21] 110
[22] 106
After I combine and split with sort on
item 1 I get this...
[1] 1,22
[2] 10,118
[3] 11,169
[4] 12,159
[5] 13,158
[6] 14,105
[7] 15,76
[8] 16,52
[9] 17,81
[10] 18,52
[11] 19,132
[12] 2,88
[13] 20,82
[14] 21,110
[15] 22,106
[16] 3,78
[17] 4,80
[18] 5,102
[19] 6,96
[20] 7,77
[21] 8,122
[22] 9,114
and when I sort on item 2 I get this...
6,100
5,106
22,110
13,111
12,112
21,114
9,118
10,122
11,122
8,126
19,136
1,26
16,56
18,56
14,58
15,80
7,81
3,82
4,84
17,85
20,86
2,92
Obviously neither of these is any use.
Any suggestions as to where I've gone wrong
or how to get the result I want?
some reporting of results I find that
using the arrays below gets the end
result I was looking for.
So the question now is the interpretation
of the array which still seems obscure to me.
But I suppose I should be satisfied with a result.
-------------------------------------------------------
I have an array....
[1] 22
[2] 88
[3] 78
[4] 80
[5] 102
[6] 96
[7] 77
[8] 122
[9] 114
[10] 118
[11] 169
[12] 159
[13] 158
[14] 105
[15] 76
[16] 52
[17] 81
[18] 52
[19] 132
[20] 82
[21] 110
[22] 106
After I combine and split with sort on
item 1 I get this...
[1] 1,22
[2] 10,118
[3] 11,169
[4] 12,159
[5] 13,158
[6] 14,105
[7] 15,76
[8] 16,52
[9] 17,81
[10] 18,52
[11] 19,132
[12] 2,88
[13] 20,82
[14] 21,110
[15] 22,106
[16] 3,78
[17] 4,80
[18] 5,102
[19] 6,96
[20] 7,77
[21] 8,122
[22] 9,114
and when I sort on item 2 I get this...
6,100
5,106
22,110
13,111
12,112
21,114
9,118
10,122
11,122
8,126
19,136
1,26
16,56
18,56
14,58
15,80
7,81
3,82
4,84
17,85
20,86
2,92
Obviously neither of these is any use.
Any suggestions as to where I've gone wrong
or how to get the result I want?