Sequential Layout of Script-created Objects

erik hansen erikhans08 at yahoo.com
Tue Dec 10 21:10:01 EST 2002


--- Dar Scott <dsc at swcp.com> wrote:
> >> repeat with x = the number of controls of
> group
> >> "grpButtons" of stack down to 1
> > or
> > put (the number of controls of group
> "grpButtons"
> > of stack) into tot
> > repeat with x = tot down to 1
> > a little faster and you can see the total.
> > from the Winkler book.
> 
> On my system the first takes 30 microseconds
> and the second takes about 
> 100.  I get similar results if I include the
> entire loop in the timing.
> 
> Maybe this applies to an earlier 'card or the
> book example is confusing.

i was afraid something like this would happen.
a recent DeVoto (co-author of The Book) posted
that x is only calculated once. maybe that lets
the former go faster. i still like seeing the
total in a local variable when trouble shooting.

=====
erik at erikhansen.org    http://www.erikhansen.org

__________________________________________________
Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
http://mailplus.yahoo.com



More information about the use-livecode mailing list