Oh mann ...
eindeutig überarbeitet, soviel Mist wie ich heute produziere ... (ich sollte aufhörn für heute)
// as: array zum sortieren
temparray = new array();
function asort(spalte)
{
for(i=0; i<as.length; i++)
{ ta(i);
for(j=i+1; j<as.length; j++)
{ if(temparray[i][spalte]>as[i][spalte])
ta(j); }
at(i);
}
function ta(i)
{ for(j=0; j<as[i].length; j++)
temparray[i][j] = as[i][j]; }
Was ein Käse ...
temparray[j] = as[i][j]; }
... ist richtig
function at(i)
{ for(j=0; j<temparray.length; j++)
as[i][j] = temparray[i][j]; }
Und der gleiche Käse nochmal:
as[i][j] = temparray[j]; }
... ist richtig.
Ciao,
Harry
(übermüdet)