• 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: Son of Silly Ball and Rand()
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Son of Silly Ball and Rand()


  • Subject: Re: Son of Silly Ball and Rand()
  • From: Andreas Monitzer <email@hidden>
  • Date: Tue, 7 Aug 2001 14:06:57 +0200

On Tuesday, August 7, 2001, at 01:50 , jean-michel daix wrote:

The cocoa version of Silly Ball use Rand() to create a random Number. Those
someone now where this function is documented ? How to create a RandSeed in
cocoa ?

rand is obsolete, use random:

man 3 random

NAME
random, srandom, initstate, setstate - better random number generator;
routines for changing generators

SYNOPSIS
#include <stdlib.h>

long
random(void)

void
srandom(unsigned seed)

char *
initstate(unsigned seed, char *state, int n)

char *
setstate(char *state)
[...]

andy
--
"He was addicted to life. But we cured him"


References: 
 >Son of Silly Ball and Rand() (From: jean-michel daix <email@hidden>)

  • Prev by Date: Son of Silly Ball and Rand()
  • Next by Date: Autorelease pool - was Beginners question regarding NSFileHandle
  • Previous by thread: Son of Silly Ball and Rand()
  • Next by thread: Autorelease pool - was Beginners question regarding NSFileHandle
  • Index(es):
    • Date
    • Thread