repeat with i=
Klaus on-rev
klaus at major.on-rev.com
Thu Jul 14 11:35:14 EDT 2011
Hi Ron,
Am 14.07.2011 um 17:06 schrieb Ronald Zellner:
> Jim's seems to be the most efficient and accurate,
> but I needed this change to make it work. ' of ' changed to 'in'
>
> I like to add something to create quick feedback- like the field "chosen".
> Easier to see the result.
> Then switch to the complete function when the code is working.
> ...
>
> This is a variant to Keith's:
> It stops at 6 items, but it still has the problem of repeating some numbers that are still in the list.
Sure: any(y) probably <> z :-)
> on mouseUp
> local x, y, z
> put empty into field "chosen"
> put "1,2,3,4,5,6" into x
> repeat with z = 1 to 6
> put any item of x into y
> put y & return after field "chosen"
> delete item y of x
> end repeat
> end mouseUp
on mouseUp
local x, y, z
put empty into field "chosen"
put "1,2,3,4,5,6" into x
repeat with z = 1 to 6
put random(the num of items of x) into y
put item y of x & return after field "chosen"
delete item y of x
end repeat
end mouseUp
> Ron
Best
Klaus
--
Klaus Major
http://www.major-k.de
klaus at major.on-rev.com
More information about the use-livecode
mailing list