• 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
AS 1.6 Random Number Bug?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

AS 1.6 Random Number Bug?


  • Subject: AS 1.6 Random Number Bug?
  • From: Craig Simons <email@hidden>
  • Date: Thu, 29 Mar 2001 13:57:27 -0700

I just installed AppleScript 1.6 and some random-number applets became
non-random. The following script begins cycling within 3 iterations, but did
not prior to AS 1.6.

set the_List to {}
set kernal to (current date)
set the_Number to (random number from 1 to 9999 with seed kernal)
if (the_Number is in the_List) then
display dialog "Yikes! " & the_Number & " is in the list!!"
else
set the_List to the_List & the_Number
end if
set the kernal to (random number with seed kernal)
delay 4
end repeat

This behavior occurs with constants (.1, .9, 9999, etc.) and with Jon's
Commands "the ticks".

Any suggestions or is it broken?

TIA,
Craig Simons
Mac Net/Sys Admin at-large


  • Prev by Date: Re: [OFF] path to documents folder?
  • Next by Date: Re: Automatic Screen Snapshot?
  • Previous by thread: Re: A choose application question
  • Next by thread: Re: AS 1.6 Random Number Bug?
  • Index(es):
    • Date
    • Thread