Re: loops [naming variables]
Re: loops [naming variables]
- Subject: Re: loops [naming variables]
- From: has <email@hidden>
- Date: Mon, 18 Feb 2002 00:13:19 +0000
Emmanuel wrote:
>
The problem is, a given variable won't keep the same status in successive
>
lines. (actually, this is the very spirit of programmation: you apply
>
routines intended for "a" thing to "your" thing). One should then write:
>
>
>
repeat with eachVegetable in thevegetableBasket
>
copy eachVegetable to theCandidateVegetable
>
if theCandidateVegetable blah blah the
>
copy theCandidateVegetable to theNewSelectedVegetable
>
set end of theSelectedBasked to theNewSelectedVegetable
>
else
>
copy theCandidateVegetable to theNoGoodFood
>
-- whoever you are, whatever you do, never try this at home
>
delete item theNoGoodFood from thevegetableBasket
>
end
>
end
I see major potential for inventing a programming language where the
operating metaphor is changes in variable names. One for theoretical
language designers to play with...
>
PS
>
"delete item anItem from aList" is a new feature in AppleScript 2.0.0
Except I want to delete THEItem - NOT anItem - and can't figure how to do
this in LevyScript. Help!
has ;)
_______________________________________________
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.