Message-ID: <3B547D7E.A1DBB9A2@earthlink.net> From: Martin Ambuhl X-Mailer: Mozilla 4.77 [en] (Win95; U) X-Accept-Language: en,zh-CN,fr,de-CH,ru MIME-Version: 1.0 Newsgroups: comp.os.msdos.djgpp Subject: Re: random generator References: <591c995d39584286 DOT 39584286591c995d AT poczta DOT arena DOT pl> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Lines: 9 Date: Tue, 17 Jul 2001 17:59:07 GMT NNTP-Posting-Host: 209.246.75.12 X-Complaints-To: abuse AT earthlink DOT net X-Trace: newsread2.prod.itd.earthlink.net 995392747 209.246.75.12 (Tue, 17 Jul 2001 10:59:07 PDT) NNTP-Posting-Date: Tue, 17 Jul 2001 10:59:07 PDT Organization: EarthLink Inc. -- http://www.EarthLink.net X-Received-Date: Tue, 17 Jul 2001 10:56:31 PDT (newsmaster1.prod.itd.earthlink.net) To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com Jan Kowalski wrote: > > Hi ! > > I have some problems with random generator. I use rand() function to > generate random valua. When I start my program evrey time its generates > the same value. What am I doing with it ? :( Forgetting to seed the RNG. See srand() for a solution.