Re: list question
Re: list question
- Subject: Re: list question
- From: Jon Pugh <email@hidden>
- Date: Wed, 4 Jun 2003 14:16:27 -0700
At 11:09 AM -0600 6/4/03, Doug McNutt wrote:
>
set a to 2
>
set b to a
>
set c to a + b
>
c
>
--> 4
>
set a to a + 1
>
set c to a + b
>
c
>
--> 5
>
>
Can you explain just how "b" here refers to the same object as "a". Why doesn't the second calculation return 6? (I'd really be upset if it did!)
set nums to {1, 2, 3, 4, 5}
set a to a reference to item 2 of nums
set b to a
set c to a + b
set contents of a to a + 1
set d to a + b
{a, b, c, d, nums}
Does this make any more sense?
Jon
_______________________________________________
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.