version	U12.1.00
uid	convert.u1-1786032978-0
impl	error
global	3
	0,000005,exbase10,2
	1,000005,inbase10,2
	2,000005,radcon,3

proc exbase10
	local	0,001000,i
	local	1,001000,j
	local	2,000020,s
	local	3,000020,d
	local	4,000020,sign
	local	5,000040,digits
	local	6,000000,stop
	con	0,002000,1,2
	con	1,010000,21,052,052,052,040,142,141,163,145,040,157,165,164,040,157,146,040,162,141,156,147,145
	con	2,002000,1,0
	con	3,010000,1,055
	con	4,010000,0
	con	5,002000,1,9
	con	6,002000,1,1
	declend
	filen	convert.icn
	line	28
	colm	11
	synt	any
lab L1
	init	L3
	mark	L2
	pnull
	var	5
	pnull
	pnull
	line	32
	colm	22
	synt	any
	keywd	digits
	line	32
	colm	33
	synt	any
	keywd	lcase
	line	32
	colm	30
	synt	any
	cat
	line	32
	colm	43
	synt	any
	keywd	ucase
	line	32
	colm	40
	synt	any
	cat
	line	32
	colm	19
	synt	any
	asgn
	unmark
lab L2
	einit	L1
lab L3
	mark	L4
	line	34
	colm	4
	synt	if
	mark0
	mark	L5
	pnull
	pnull
	int	0
	var	1
	line	34
	colm	13
	synt	any
	numle
	pnull
	var	5
	line	34
	colm	21
	synt	any
	size
	line	34
	colm	18
	synt	any
	numle
	unmark
	efail
lab L5
	pnull
	unmark
	var	6
	str	1
	line	34
	colm	39
	synt	any
	invoke	1
	line	34
	colm	4
	synt	endif
	unmark
lab L4
	mark	L6
	line	36
	colm	4
	synt	if
	mark0
	pnull
	var	0
	int	2
	line	36
	colm	9
	synt	any
	numeq
	unmark
	mark	L7
	int	2
	line	36
	colm	18
	synt	any
	pret
lab L7
	synt	any
	pfail
	line	36
	colm	4
	synt	endif
	unmark
lab L6
	mark	L8
	line	38
	colm	4
	synt	ifelse
	mark	L9
	pnull
	var	0
	int	2
	line	38
	colm	9
	synt	any
	numlt
	unmark
	mark	L11
	pnull
	var	4
	str	3
	line	39
	colm	12
	synt	any
	asgn
	unmark
lab L11
	pnull
	var	0
	pnull
	var	0
	line	40
	colm	12
	synt	any
	neg
	line	40
	colm	9
	synt	any
	asgn
	goto	L10
lab L9
	pnull
	var	4
	str	4
	line	42
	colm	14
	synt	any
	asgn
lab L10
	line	38
	colm	4
	synt	endifelse
	unmark
lab L8
	mark	L12
	pnull
	var	2
	str	4
	line	43
	colm	6
	synt	any
	asgn
	unmark
lab L12
	mark	L13
lab L14
	line	44
	colm	4
	synt	while
	mark0
	pnull
	var	0
	int	2
	line	44
	colm	12
	synt	any
	numgt
	unmark
	mark	L14
	mark	L17
	pnull
	var	3
	pnull
	var	0
	var	1
	line	45
	colm	14
	synt	any
	mod
	line	45
	colm	9
	synt	any
	asgn
	unmark
lab L17
	mark	L18
	line	46
	colm	7
	synt	if
	mark0
	pnull
	var	3
	int	5
	line	46
	colm	12
	synt	any
	numgt
	unmark
	pnull
	var	3
	pnull
	var	5
	pnull
	var	3
	int	6
	line	46
	colm	35
	synt	any
	plus
	line	46
	colm	32
	synt	any
	subsc
	line	46
	colm	23
	synt	any
	asgn
	line	46
	colm	7
	synt	endif
	unmark
lab L18
	mark	L19
	pnull
	var	2
	pnull
	var	3
	var	2
	line	47
	colm	14
	synt	any
	cat
	line	47
	colm	9
	synt	any
	asgn
	unmark
lab L19
	pnull
	var	0
	dup
	var	1
	line	48
	colm	9
	synt	any
	div
	asgn
lab L15
	unmark
	goto	L14
lab L16
	line	44
	colm	4
	synt	endwhile
	unmark
lab L13
	mark	L20
	mark	L21
	pnull
	var	4
	var	2
	line	51
	colm	16
	synt	any
	cat
	line	51
	colm	4
	synt	any
	pret
lab L21
	synt	any
	pfail
	unmark
lab L20
	pnull
	line	53
	colm	1
	synt	any
	pfail
	end
proc inbase10
	local	0,001000,s
	local	1,001000,i
	local	2,000000,stop
	local	3,000000,integer
	con	0,002000,2,36
	con	1,010000,33,052,052,052,040,142,141,163,145,040,164,157,157,040,154,141,162,147,145,040,146,157,162,040,151,156,142,141,163,145,061,060,050,051
	con	2,002000,1,1
	con	3,010000,1,055
	con	4,010000,1,162
	con	5,002000,1,2
	con	6,002000,1,0
	declend
	line	55
	colm	11
	synt	any
	mark	L1
	line	57
	colm	4
	synt	if
	mark0
	pnull
	var	1
	int	0
	line	57
	colm	9
	synt	any
	numgt
	unmark
	var	2
	str	1
	line	57
	colm	23
	synt	any
	invoke	1
	line	57
	colm	4
	synt	endif
	unmark
lab L1
	mark	L2
	line	59
	colm	4
	synt	ifelse
	mark	L3
	pnull
	pnull
	var	0
	int	2
	line	59
	colm	8
	synt	any
	subsc
	str	3
	line	59
	colm	12
	synt	any
	lexeq
	unmark
	mark	L5
	pnull
	str	3
	var	3
	pnull
	pnull
	var	1
	str	4
	line	59
	colm	48
	synt	any
	cat
	pnull
	var	0
	int	5
	int	6
	line	59
	colm	61
	synt	any
	synt	any
	sect
	line	59
	colm	55
	synt	any
	cat
	line	59
	colm	45
	synt	any
	invoke	1
	line	59
	colm	35
	synt	any
	cat
	line	59
	colm	24
	synt	any
	pret
lab L5
	synt	any
	pfail
	goto	L4
lab L3
	mark	L6
	var	3
	pnull
	pnull
	var	1
	str	4
	line	60
	colm	26
	synt	any
	cat
	var	0
	line	60
	colm	33
	synt	any
	cat
	line	60
	colm	23
	synt	any
	invoke	1
	line	60
	colm	9
	synt	any
	pret
lab L6
	synt	any
	pfail
lab L4
	line	59
	colm	4
	synt	endifelse
	unmark
lab L2
	pnull
	line	62
	colm	1
	synt	any
	pfail
	end
proc radcon
	local	0,001000,s
	local	1,001000,i
	local	2,001000,j
	local	3,000000,exbase10
	local	4,000000,inbase10
	declend
	line	64
	colm	11
	synt	any
	mark	L1
	mark	L2
	var	3
	var	4
	var	0
	var	1
	line	66
	colm	28
	synt	any
	invoke	2
	var	2
	line	66
	colm	19
	synt	any
	invoke	2
	line	66
	colm	4
	synt	any
	pret
lab L2
	synt	any
	pfail
	unmark
lab L1
	pnull
	line	68
	colm	1
	synt	any
	pfail
	end
