Re: can I do this better?
Re: can I do this better?
- Subject: Re: can I do this better?
- From: Ric Phillips <email@hidden>
- Date: Fri, 14 Jun 2002 09:56:50 +1000
On 14/6/02 3:11 AM, "Eric Phillips" <email@hidden> wrote:
>
In an attempt to learn more I have been reading this thread. I have one
>
question from Ric Phillips' sample. Why do you use "every character of s"? Why
>
wouldn't you just say "does not contain item i of s then"? A snippet of Ric's
>
code is below.
>
>
Ye Gads!!!
Another Eric Phillips! (Ric is short for Eric) That's kind of spooky.
The answer to the question is simple - readability. My thinking was that
when compiled, 'character i of s' and 'item i of (every character of s)'
would be the same. But then, in light of another post I am not sure if these
will compile the same way. And looking at it again, I would say now, that it
is six of one half dozen of the other as to whether it is more or less
readable. One makes the underlying logic a little clearer, and one is more
English like (and so more attuned to the AS way).
On balance, I think I would go with "does not contain character i of s", on
readability grounds. I suspect it will still compile to a list operation,
and so shouldn't change the run time parameters all that much.
(Any AS engineers want to comment?)
Cheers,
Ric Phillips
Faculty Web Coordinator
Faculty of Humanities and Social Sciences
Latrobe University
Room HU3 324
Phone: 9479 2792
-----------------------------------------
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.