arraybase 1 dim flag = {"Red","White","Blue"} dim balls(9) print "Random: |"; for i = 1 to 9 kolor = (rand * 3) + 1 balls[i] = flag[kolor] print balls[i]; " |"; next i print print "Sorted: |"; for i = 1 to 3 kolor = flag[i] for j = 1 to 9 if balls[j] = kolor then print balls[j]; " |"; next j next i