[Razz] Yippee!! [Big Grin] [Eek!]

You were right Jooel, there was another stroke to be cut. [Wink]

For those interested in the code, please take note that "$" is used in two different scopes.

code:
function CDSorter($w, $)
Dim $x, $b
do
$x = split($w,",")
do
$b=0.
Dim $z,$q,$
for each $q in $x
$=1+$
if $q
$b = $b + $q
$z=$z+","+$
endif
next
$x[RND($-2)]=0
$CDSorter=substr($z,2)
until $b < $
until $b > $-1
endfunction

code:
Average CD Length = 44.43
Average Gap = 0.57
Average Gap [%] = 1.26

KiXtart
KiXtart Version = 4.21 Release Candidate 1
KiXGolf Script = kixgolf_cd.kix

Computer
OS = Windows 2000 Professional
CPU = Intel Pentium III
Speed = 848 MHz
Memory = 511 MB

KiXGolf Scoring Engine
Scoring Engine = 3.0.3

KiXtart Golf Score
Tournament = KiXtart Golf: CD Sorter
Processing Start = 2003/03/16 16:01:26.692
Processing End = 2003/03/16 16:01:29.416
Duration = 0000/00/00 00:00:02.723
# Loops = 1
# Processed CDs = 12
# Valid CDs = 12
# Full CDs = 0
KiXGolf Result = Valid CD Filling
KiXGolf Score = 182

Thank you for participating in KiXtart Golf!



[ 17. March 2003, 03:31: Message edited by: Howard Bullock ]
_________________________
Home page: http://www.kixhelp.com/hb/