• 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: loops vs no loops ?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: loops vs no loops ?


  • Subject: Re: loops vs no loops ?
  • From: Steve Bird <email@hidden>
  • Date: Sat, 4 Nov 2017 09:37:05 -0400

> On Nov 4, 2017, at 9:31 AM, Jean-Christophe Helary
> <email@hidden> wrote:
>
> It's probably a detail but I'm curious.
>
> What is the best between (pseudo code):
>
> if true
>       do action 1 to 4
> else
>       do action 4
> end if
>
> and
>
> if true
>       do action 1 to 3
> end if
> do action 4
>

If action 4 is long and complicated, then:
— you have to type it twice, raising the issue of a mismatch.
— If you decide to change it, you have to change it TWICE.

I would always choose option B.


----------------------------------------------------------------
Steve Bird
Culverson Software - Elegant software that is a pleasure to use.
www.Culverson.com                     (toll free) 1-877-676-8175




 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

  • Follow-Ups:
    • Re: loops vs no loops ?
      • From: Jean-Christophe Helary <email@hidden>
References: 
 >loops vs no loops ? (From: Jean-Christophe Helary <email@hidden>)

  • Prev by Date: loops vs no loops ?
  • Next by Date: Re: loops vs no loops ?
  • Previous by thread: loops vs no loops ?
  • Next by thread: Re: loops vs no loops ?
  • Index(es):
    • Date
    • Thread