random number generator

Discussion in 'C++' started by iandigges@gmail.com, Apr 25, 2007.

  1. Guest

    I need a random number generator to produce a 0 or 1 that I can feed
    into a multidimensional array. Any hints?

    ~ Ian
     
    , Apr 25, 2007
    #1
    1. Advertising

  2. James Kanze Guest

    On Apr 25, 7:29 pm, wrote:
    > I need a random number generator to produce a 0 or 1 that I can feed
    > into a multidimensional array. Any hints?


    Boost has exactly what you are looking for, see
    http://www.boost.org/libs/random/index.html, and in particular,
    the distribution uniform_01.

    --
    James Kanze (GABI Software) email:
    Conseils en informatique orientée objet/
    Beratung in objektorientierter Datenverarbeitung
    9 place Sémard, 78210 St.-Cyr-l'École, France, +33 (0)1 30 23 00 34
     
    James Kanze, Apr 26, 2007
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Kingsley Oteng

    Random Number Generator??

    Kingsley Oteng, Apr 27, 2004, in forum: VHDL
    Replies:
    11
    Views:
    52,391
    rahul.iyer
    Aug 9, 2010
  2. tshad

    Random number/letter generator

    tshad, May 5, 2005, in forum: ASP .Net
    Replies:
    3
    Views:
    9,577
    tshad
    May 6, 2005
  3. Wally
    Replies:
    1
    Views:
    2,807
    pvdg42
    Mar 20, 2006
  4. globalrev
    Replies:
    4
    Views:
    782
    Gabriel Genellina
    Apr 20, 2008
  5. VK
    Replies:
    15
    Views:
    1,210
    Dr J R Stockton
    May 2, 2010
Loading...

Share This Page