✔ 最佳答案
Do you mean you have a string and want to add 8 characters TO the existing string?Or, do you have an array and want to add elements to the array, each with a set of 8 random numbers? Let's go for appending 8 random number characters as that is easier to run through than the array...
s$=""
a$="0123456789"
randomize 'initialize the random number generator
x = 0
for y=1 to 8
x=random(len(a$)) 'select a random number from 0 to length of a$
a$=s$=s$+substr(a$,x,1) ' append the number character
next y
print s$ ' print the 8 character number string
-=+=-
Is this the kind of thing you wish to do? Note that in this example, single digits CAN repeat within the string.