• 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: How do I get the decimals?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How do I get the decimals?


  • Subject: Re: How do I get the decimals?
  • From: Emmanuel <email@hidden>
  • Date: Fri, 30 Jul 2004 00:01:56 +0200

At 5:54 PM -0300 29/07/04, Bernardo Hoehl wrote:
>Example:
>
>set x to 266 div 11--- returns 24
>
>the true calculation should return 24.18181818 or a rest of 2
>
>Question: how do I get the rest of the calculation?

AppleScript knows the usual four operators on real numbers: + - / *, what you want is "266/11".

One chapter on the site of Satimage-software is dedicated to maths and AppleScript:

<http://www.satimage.fr/software/en/as_maths.html>

You may want to give it an eye.

Emmanuel
_______________________________________________
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.


References: 
 >How do I get the decimals? (From: Bernardo Hoehl <email@hidden>)

  • Prev by Date: Re: Too simple to find an answer for...
  • Next by Date: Re: Getting the default language with AppleScript
  • Previous by thread: Re: How do I get the decimals?
  • Next by thread: Re: How do I get the decimals?
  • Index(es):
    • Date
    • Thread