home *** CD-ROM | disk | FTP | other *** search
/ Programmer 7500 / MAX_PROGRAMMERS.iso / INFO / MISC / IFP05.ZIP / FPDEMO.EXE / SLOWSORT < prev    next >
Encoding:
Text File  |  1987-02-09  |  244 b   |  13 lines

  1. (*
  2.  * SlowSort
  3.  *
  4.  * Sort a sequence the hard way, i.e. take all permutations
  5.  * and pick one for which all elements are in order.
  6.  *)
  7. DEF SlowSort AS
  8.    Permute | 
  9.    FILTER 
  10.       [tl,tlr]|trans | EACH >= END | all 
  11.    END | 1;
  12.  
  13.