Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!seismo!gatech!amdcad!bandy From: bandy@amdcad.AMD.COM (Andy Beals) Newsgroups: comp.sources.d Subject: Re: rot2 - waterfall terminal display Message-ID: <16814@amdcad.AMD.COM> Date: Tue, 26-May-87 13:01:44 EDT Article-I.D.: amdcad.16814 Posted: Tue May 26 13:01:44 1987 Date-Received: Thu, 28-May-87 02:28:23 EDT References: <507@titan.camcon.co.uk> <6800001@cpe> Reply-To: bandy@amdcad.UUCP (Andy Beals) Organization: Advanced Micro Devices, Inc., Sunnyvale, Ca. Lines: 15 In article <6800001@cpe> tif@cpe.UUCP writes: ^^^^^^^ down with notes! >For equal portions of "water" to "fall" on each side of an obstacle >the following change should be made to rot.c on line 395 (?): > > else if(rand()&01000) { >Should be > else if(rand()&1) { Nope. rand() doesn't give truely random numbers, just pseudo-random numbers. Try writing a little program that prints the output of rand()&1 and note what you get out. Not random at all. andy -- Andrew Scott Beals, {lll-crg,decwrl,allegra}!amdcad!bandy +1 408 749 3683