MACSCRPT Archives

February 2009

MACSCRPT@LISTSERV.DARTMOUTH.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
"Mark J. Reed" <[log in to unmask]>
Reply To:
Macintosh Scripting Systems <[log in to unmask]>
Date:
Thu, 5 Feb 2009 14:57:59 -0500
Content-Type:
text/plain
Parts/Attachments:
text/plain (32 lines)
On Thu, Feb 5, 2009 at 2:50 PM, Christian Huldt <[log in to unmask]> wrote:
> Any comments on

Every time you do a concatenation AS builds a new list from scratch.
Set end just modifies the existing list in place.  Seems pretty
straightforward.

It will speed things up further if you make b a property.  Also, you
could do "repeat 10000 times" and get rid of the i var.

> (well, other than the increasingly peculiar semi-circular reasoning of something like do shell script "perl -e 'print time'")

I have no idea why you would do that.

set t0 to curent date
...
set t1 to current date

{t1 - t0}


If you actually need to get at the time_t value for some reason, you
can still do it without Perl:

do shell script "date +%s"

There are things that it makes sense to use Perl for - this is not one
of them.  I think two interpreters at a time is a good maximum to
strive for.
-- 
Mark J. Reed <[log in to unmask]>

ATOM RSS1 RSS2