divert(-1)
# @(#)Copyright (c), 1987, 1993 StatSci, Inc.  All rights reserved.
define(`TEST',`$1 $2 $3')
define(`FUNCTION',`define(`TEST',`fun($'`1,$'`3) $'`2 0')')
define(`ORDER',`
integer save,t,j,nbd
if(n<2) return
for(t=n; t>0; ){
	nbd=t
	t=0
	for(j=1; j<nbd; j=j+1)
		if(TEST(x(key(j)),>,x(key(j+1)))){
			save=key(j)
			key(j)=key(j+1)
			key(j+1)=save
			t=j
			}
	}
return
')
divert(0)
SCCS_ID(95982,`@(#)'order.m 3.9 last edit 2/20/93 StatSci. From BASEFILE)
