proc rand_num
	filen	random.icn
	local	0,001000,a_
	local	1,001000,c_
	local	2,001000,m_
	local	3,000040,random_last
	local	4,000040,a
	local	5,000040,c
	local	6,000040,m
	local	7,000000,random
	con	0,002000,1,0
	con	1,002000,10,1103515245
	con	2,002000,9,453816694
	con	3,002000,1,2
	con	4,002000,2,31
	declend
	line	64
	colm	11
	init	L1
	mark	L1
	mark	L2
	pnull
	pnull
	var	7
	line	68
	colm	7
	null
	int	0
	line	68
	colm	15
	asgn
	unmark
lab L2
	mark	L3
	pnull
	var	4
	mark	L4
	pnull
	var	0
	line	69
	colm	12
	nonnull
	esusp
	goto	L5
lab L4
	int	1
lab L5
	line	69
	colm	9
	asgn
	unmark
lab L3
	mark	L6
	pnull
	var	5
	mark	L7
	pnull
	var	1
	line	70
	colm	12
	nonnull
	esusp
	goto	L8
lab L7
	int	2
lab L8
	line	70
	colm	9
	asgn
	unmark
lab L6
	pnull
	var	6
	mark	L9
	pnull
	var	2
	line	71
	colm	13
	nonnull
	esusp
	goto	L10
lab L9
	pnull
	int	3
	int	4
	line	71
	colm	21
	power
lab L10
	line	71
	colm	9
	asgn
	unmark
lab L1
	mark	L11
	mark	L12
	pnull
	var	7
	pnull
	pnull
	pnull
	var	4
	var	7
	line	74
	colm	25
	mult
	var	5
	line	74
	colm	34
	plus
	var	6
	line	74
	colm	39
	mod
	line	74
	colm	19
	asgn
	line	74
	colm	5
	pret
lab L12
	pfail
	unmark
lab L11
	pnull
	line	76
	colm	1
	pfail
	end
proc rand_int
	local	0,001000,i
	local	1,000040,scale
	local	2,000000,integer
	local	3,000000,runerr
	local	4,000000,rand_num
	con	0,004000,1.0
	con	1,002000,1,2
	con	2,002000,2,31
	con	3,002000,1,1
	con	4,002000,1,0
	con	5,002000,3,205
	declend
	line	78
	colm	11
	init	L1
	mark	L1
	pnull
	var	1
	pnull
	real	0
	pnull
	pnull
	int	1
	int	2
	line	81
	colm	30
	power
	int	3
	line	81
	colm	35
	minus
	line	81
	colm	25
	div
	line	81
	colm	18
	asgn
	unmark
lab L1
	mark	L2
	mark	L3
	pnull
	var	0
	pnull
	int	4
	var	2
	var	0
	line	83
	colm	22
	invoke	1
	line	83
	colm	13
	numlt
	line	83
	colm	7
	asgn
	esusp
	goto	L4
lab L3
	var	3
	int	5
	var	0
	line	83
	colm	36
	invoke	2
lab L4
	unmark
lab L2
	mark	L5
	mark	L6
	pnull
	var	2
	pnull
	pnull
	var	0
	var	4
	line	85
	colm	31
	invoke	0
	line	85
	colm	21
	mult
	var	1
	line	85
	colm	34
	mult
	line	85
	colm	18
	invoke	1
	int	3
	line	85
	colm	43
	plus
	line	85
	colm	4
	pret
lab L6
	pfail
	unmark
lab L5
	pnull
	line	87
	colm	1
	pfail
	end
proc randomize
	local	0,000020,f
	local	1,000020,s
	local	2,000020,i
	local	3,000040,ncalls
	local	4,000000,open
	local	5,000000,reads
	local	6,000000,close
	local	7,000000,ord
	local	8,000000,map
	con	0,002000,1,0
	con	1,002000,1,1
	con	2,010000,12,057,144,145,166,057,165,162,141,156,144,157,155
	con	3,010000,2,162,165
	con	4,002000,1,4
	con	5,002000,3,167
	con	6,010000,6,163,123,155,115,150,110
	con	7,010000,8,110,150,072,115,155,072,123,163
	con	8,010000,8,131,171,130,170,115,155,104,144
	con	9,010000,10,131,171,130,170,057,115,155,057,104,144
	con	10,002000,4,1009
	declend
	line	89
	colm	11
	init	L1
	mark	L1
	pnull
	var	3
	int	0
	line	92
	colm	19
	asgn
	unmark
lab L1
	mark	L2
	pnull
	var	3
	dup
	int	1
	line	94
	colm	11
	plus
	asgn
	unmark
lab L2
	mark	L3
	mark0
	pnull
	var	0
	var	4
	str	2
	str	3
	line	96
	colm	16
	invoke	2
	line	96
	colm	9
	asgn
	unmark
	mark	L4
	pnull
	var	1
	var	5
	var	0
	int	4
	line	97
	colm	17
	invoke	2
	line	97
	colm	9
	asgn
	unmark
lab L4
	mark	L5
	var	6
	var	0
	line	98
	colm	12
	invoke	1
	unmark
lab L5
	mark0
	pnull
	pnull
	pnull
	var	1
	line	99
	colm	11
	nonnull
	line	99
	colm	10
	size
	int	0
	line	99
	colm	14
	numgt
	unmark
	mark	L6
	pnull
	line	100
	colm	10
	keywd	random
	int	1
	line	100
	colm	18
	asgn
	unmark
lab L6
	mark	L7
	mark0
	pnull
	var	2
	var	7
	pnull
	var	1
	line	101
	colm	25
	bang
	line	101
	colm	24
	invoke	1
	line	101
	colm	18
	asgn
	pop
	mark0
	pnull
	line	102
	colm	13
	keywd	random
	pnull
	pnull
	int	5
	line	102
	colm	30
	keywd	random
	line	102
	colm	28
	mult
	var	2
	line	102
	colm	38
	plus
	line	102
	colm	21
	asgn
	unmark
lab L8
	efail
lab L9
	unmark
lab L7
	mark	L10
	pnull
	line	103
	colm	10
	pret
lab L10
	pfail
	unmark
lab L3
	mark	L11
	pnull
	line	107
	colm	4
	keywd	random
	pnull
	pnull
	pnull
	var	8
	str	6
	str	7
	line	107
	colm	41
	keywd	clock
	line	107
	colm	18
	invoke	3
	var	8
	str	8
	str	9
	line	108
	colm	37
	keywd	date
	line	108
	colm	10
	invoke	3
	line	107
	colm	49
	plus
	line	108
	colm	46
	keywd	time
	line	108
	colm	44
	plus
	pnull
	int	10
	var	3
	line	108
	colm	59
	mult
	line	108
	colm	52
	plus
	line	107
	colm	12
	asgn
	unmark
lab L11
	mark	L12
	mark	L13
	pnull
	line	110
	colm	4
	pret
lab L13
	pfail
	unmark
lab L12
	pnull
	line	112
	colm	1
	pfail
	end
proc randrange
	local	0,001000,min
	local	1,001000,max
	con	0,002000,1,1
	declend
	line	114
	colm	11
	mark	L1
	mark	L2
	pnull
	pnull
	var	0
	int	0
	line	116
	colm	15
	minus
	pnull
	pnull
	pnull
	var	1
	var	0
	line	116
	colm	27
	minus
	int	0
	line	116
	colm	33
	plus
	line	116
	colm	21
	random
	line	116
	colm	19
	plus
	line	116
	colm	4
	pret
lab L2
	pfail
	unmark
lab L1
	pnull
	line	118
	colm	1
	pfail
	end
proc randrangeseq
	local	0,001000,i
	local	1,001000,j
	local	2,000020,x
	local	3,000020,m
	local	4,000020,a
	local	5,000020,c
	local	6,000020,n
	local	7,000000,nxtprime
	con	0,002000,1,1
	con	1,002000,1,0
	declend
	line	120
	colm	11
	mark	L1
	pnull
	var	6
	pnull
	pnull
	var	1
	var	0
	line	123
	colm	11
	minus
	int	0
	line	123
	colm	15
	plus
	line	123
	colm	6
	asgn
	unmark
lab L1
	mark	L2
	mark0
	pnull
	var	6
	int	1
	line	125
	colm	9
	numlt
	unmark
	line	125
	colm	18
	pfail
	unmark
lab L2
	mark	L3
	pnull
	var	2
	int	0
	line	127
	colm	6
	asgn
	unmark
lab L3
	mark	L4
	pnull
	var	3
	var	7
	var	6
	line	128
	colm	17
	invoke	1
	line	128
	colm	6
	asgn
	unmark
lab L4
	mark	L5
	pnull
	var	4
	pnull
	var	3
	int	0
	line	129
	colm	11
	plus
	line	129
	colm	6
	asgn
	unmark
lab L5
	mark	L6
	pnull
	var	5
	var	7
	var	3
	line	130
	colm	17
	invoke	1
	line	130
	colm	6
	asgn
	unmark
lab L6
	mark	L7
	mark0
	pnull
	int	0
	var	3
	push1
	line	132
	colm	12
	toby
	pop
	mark0
	mark	L10
	pnull
	var	2
	pnull
	pnull
	pnull
	var	4
	var	2
	line	133
	colm	15
	mult
	var	5
	line	133
	colm	19
	plus
	var	3
	line	133
	colm	24
	mod
	line	133
	colm	9
	asgn
	unmark
lab L10
	mark0
	pnull
	var	2
	var	6
	line	134
	colm	12
	numlt
	unmark
	mark0
	pnull
	var	2
	var	0
	line	135
	colm	20
	plus
	line	135
	colm	10
	psusp
	pop
lab L11
	efail
lab L12
	unmark
lab L8
	efail
lab L9
	unmark
lab L7
	pnull
	line	139
	colm	1
	pfail
	end
proc randseq
	local	0,001000,seed
	con	0,002000,1,1
	declend
	line	141
	colm	11
	mark	L1
	mark0
	pnull
	line	143
	colm	12
	keywd	random
	var	0
	line	143
	colm	20
	asgn
	line	143
	colm	4
	psusp
	pop
lab L2
	efail
lab L3
	unmark
lab L1
	mark	L4
	mark0
lab L7
	mark0
	pnull
	int	0
	line	144
	colm	13
	random
	chfail	L7
	esusp
	pop
	line	144
	colm	18
	keywd	random
	line	144
	colm	4
	psusp
	pop
lab L5
	efail
lab L6
	unmark
lab L4
	pnull
	line	146
	colm	1
	pfail
	end
proc rng
	local	0,001000,a
	local	1,001000,c
	local	2,001000,m
	local	3,001000,x
	local	4,000000,iand
	con	0,002000,10,1103515245
	con	1,002000,9,453816694
	con	2,002000,1,2
	con	3,002000,2,31
	con	4,002000,1,1
	con	5,002000,1,0
	declend
	line	148
	colm	11
	mark	L1
	pnull
	pnull
	var	0
	line	150
	colm	4
	null
	int	0
	line	150
	colm	7
	asgn
	unmark
lab L1
	mark	L2
	pnull
	pnull
	var	1
	line	151
	colm	4
	null
	int	1
	line	151
	colm	7
	asgn
	unmark
lab L2
	mark	L3
	pnull
	pnull
	var	2
	line	152
	colm	4
	null
	pnull
	pnull
	int	2
	int	3
	line	152
	colm	12
	power
	int	4
	line	152
	colm	17
	minus
	line	152
	colm	7
	asgn
	unmark
lab L3
	mark	L4
	pnull
	pnull
	var	3
	line	153
	colm	4
	null
	int	5
	line	153
	colm	7
	asgn
	unmark
lab L4
	mark	L5
	mark0
	var	3
	line	155
	colm	4
	psusp
	pop
lab L6
	efail
lab L7
	unmark
lab L5
	mark	L8
	mark0
	pnull
	var	3
	var	4
	pnull
	pnull
	var	0
lab L11
	mark0
	var	3
	chfail	L11
	esusp
	line	156
	colm	24
	mult
	var	1
	line	156
	colm	29
	plus
	var	2
	line	156
	colm	21
	invoke	2
	line	156
	colm	14
	asgn
	line	156
	colm	4
	psusp
	pop
lab L9
	efail
lab L10
	unmark
lab L8
	pnull
	line	158
	colm	1
	pfail
	end
proc shuffle
	local	0,001000,x
	local	1,000020,i
	local	2,000000,string
	con	0,002000,1,2
	con	1,002000,1,1
	declend
	line	165
	colm	11
	mark	L1
	pnull
	var	0
	var	2
	var	0
	line	168
	colm	15
	invoke	1
	line	168
	colm	6
	asgn
	unmark
lab L1
	mark	L2
	mark0
	pnull
	var	1
	pnull
	pnull
	var	0
	line	169
	colm	15
	size
	int	0
	pnull
	int	1
	line	169
	colm	26
	neg
	line	169
	colm	18
	toby
	line	169
	colm	12
	asgn
	pop
	mark0
	pnull
	pnull
	var	0
	pnull
	var	1
	line	170
	colm	9
	random
	line	170
	colm	8
	subsc
	pnull
	var	0
	var	1
	line	170
	colm	18
	subsc
	line	170
	colm	13
	swap
	unmark
lab L3
	efail
lab L4
	unmark
lab L2
	mark	L5
	mark	L6
	var	0
	line	171
	colm	4
	pret
lab L6
	pfail
	unmark
lab L5
	pnull
	line	172
	colm	1
	pfail
	end
