Another brute force solution:

procedure sort_letters(s)
   local i, j
   every s[i:=(2 to *s)] << s[j:=(1 to i-1)] do s[i] :=: s[j]
   return s
end

I think if 'every' is replaced by 'while' the running time
should be O(n**3), which would be a mildly perverse
accomplishment.




------------------------------------------------------- This SF.Net email is sponsored by the new InstallShield X.
From Windows to Linux, servers to mobile, InstallShield X is the
one installation-authoring solution that does it all. Learn more and
evaluate today! http://www.installshield.com/Dev2Dev/0504
_______________________________________________
Unicon-group mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/unicon-group

Reply via email to