j.tangen at unsw.edu.au
Mon Oct 31 18:22:27 CST 2005
I'm trying to solve a seemingly simple problem and I could use some
help. A coin flip will come out "Heads" or "Tails" and will produce,
for example, the following series for 20 flips:
I need to count up the number events for a particular run. For example,
Heads x 3 = 2
Heads x 2 = 0
Heads x 1 = 4
Tails x 1 = 4
Tails x 2 = 3
Tails x 3 = 0
I need to account for runs up to 60 (rather than 3 above) for
hundreds of flips (rather than 20 above).
I've been using a very clumsy multiple if-then solution to date, but
this quickly becomes difficult with many runs.
Can someone point me in the right direction?
More information about the use-livecode