; begin KiXgolf UDF
;
;!
Function S($)
dim $a[3,3,5], $sInput, $ix, $iy
for $iy=0 to 3
for $ix=0 to 3
$a[$ix,$iy,0] = $[$ix,$iy]
next
next
$sInput = 'xx41|xx23|4132|3214'
for $iy=0 to 3
for $ix=0 to 3
$a[$ix,$iy,1] = substr($sInput, $iy*5 + $ix + 1, 1)
next
next
$sInput = 'x341|xx23|4132|3214'
for $iy=0 to 3
for $ix=0 to 3
$a[$ix,$iy,2] = substr($sInput, $iy*5 + $ix + 1, 1)
next
next
$sInput = '2341|xx23|4132|3214'
for $iy=0 to 3
for $ix=0 to 3
$a[$ix,$iy,3] = substr($sInput, $iy*5 + $ix + 1, 1)
next
next
$sInput = '2341|x423|4132|3214'
for $iy=0 to 3
for $ix=0 to 3
$a[$ix,$iy,4] = substr($sInput, $iy*5 + $ix + 1, 1)
next
next
$sInput = '2341|1423|4132|3214'
for $iy=0 to 3
for $ix=0 to 3
$a[$ix,$iy,5] = substr($sInput, $iy*5 + $ix + 1, 1)
next
next
$S = $a
EndFunction
;!
;!
; end KiXgolf UDF