Re: I want to convert a list of integers to their negative self
Re: I want to convert a list of integers to their negative self
- Subject: Re: I want to convert a list of integers to their negative self
- From: Paul Berkowitz <email@hidden>
- Date: Wed, 28 Feb 2001 21:32:35 -0800
On 2/28/01 8:38 PM, "email@hidden" <email@hidden> wrote:
>
In a message dated 2/28/01 9:28:54 PM,
>
email@hidden writes:
>
>
> set a to {"1", "3", "7"}
>
>
>
> repeat with i in a
>
> set a to rest of a & i div -1
>
> end repeat
>
>
This is a great one! I'm not sure I understand exactly how it does it, but
>
thanks. One question though, only one person has even made reference to this
>
and even that person didn't try this, but why not:
>
>
set a to {1, 3, 7}
>
>
in the first place. Does the original list have to be a list of strings or
>
can you just make it a list of integers to begin with?
>
Integers will work fine, Ken. (We'll get you weaned from OneClick soon!)
--
Paul Berkowitz