• 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: Scientific notation
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Scientific notation


  • Subject: Re: Scientific notation
  • From: Michael Cytrynowicz <email@hidden>
  • Date: Fri, 02 May 2003 21:00:01 +0200

And, after syntax checking in SE2, this

set theNumber to 3.0E-3
do shell script "perl -e 'print " & theNumber & "'"

becomes this:

set theNumber to 0.003
do shell script "perl -e 'print " & theNumber & "'"

(the result is "0.003")



Mike C


---------------------
has, Jeffrey Mattox wrote:
>
>> You do good work, but all that AS for such a simple task makes me
>> cringe. How about this instead:
>>
>> set theNumber to 3.0E-4
>> do shell script "perl -e 'print " & theNumber & "'"
>> --> "0.0003"
>
> set theNumber to 3.0E-8
> do shell script "perl -e 'print " & theNumber & "'"
> --> "3.0E-8"
> (nuff said)
_______________________________________________
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.

  • Prev by Date: Re: mac to unix path names
  • Next by Date: Rules for leading colon
  • Previous by thread: Re: Scientific notation
  • Next by thread: PD 4.1 comments [was: Palm Desktop 4.1 (creating a memo)]
  • Index(es):
    • Date
    • Thread