04-23-2022, 09:33 PM
Code: (Select All)
dim c_pentatonic(0 to 4) as single
c_pentatonic(0) = 130.81
c_pentatonic(1) = 146.83
c_pentatonic(2) = 164.81
c_pentatonic(3) = 196.0
c_pentatonic(4) = 220.00
duration = 6
while inkey$ <> chr$(27)
i = int(5 * rnd + 1) - 1
print i,
freq = c_pentatonic(i)
sound freq, duration
_delay 0.5
wend