I'm adapting the Text to Pitch prototype, for a simple DNA project, with a,c,t,g. Inisde the script I have the following -
(nbr == 97) ifTrue: [nbr := 13]. "a"
Where the first number is an ASCII code, and the second number is a nn for a KeyMappedMultismaple. What I'd like to do is choose from a range of numbers, like this -
(nbr == 97) ifTrue: [nbr := randomly select from the range 13-16].
I found "Interval", from online Smalltalk documentation:
(nbr == 97) ifTrue: [nbr := Interval from: 13 to: 16].
But I can't find the code to randomly select a number from the Interval. Thanks for any help, from an amateur programmer!