• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: I want to convert a list of integers to their negative self
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

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


  • Follow-Ups:
    • Re: I want to convert a list of integers to their negative self
      • From: Devon and Cornwall <email@hidden>
References: 
 >Re: I want to convert a list of integers to their negative self (From: email@hidden)

  • Prev by Date: Re: Scripting Additions
  • Next by Date: Re: Records
  • Previous by thread: Re: I want to convert a list of integers to their negative self
  • Next by thread: Re: I want to convert a list of integers to their negative self
  • Index(es):
    • Date
    • Thread