dim a(99) as integer
dim i as integer
dim sums(9) as integer
dim index as integer
Randomize
for i=0 to 99
a(i)=int(100*rnd)
index=a(i) mod 10
sums(index)=sums(index) +1
next i
for i =0 to 9
print i "的个数是:" sums(i)
next
dim a(99) as integer
dim i as integer
dim sums(9) as integer
dim index as integer
Randomize
for i=0 to 99
a(i)=int(100*rnd)
index=a(i) mod 10
sums(index)=sums(index) +1
next i
for i =0 to 9
print i "的个数是:" sums(i)
next