Path: csiph.com!eternal-september.org!feeder.eternal-september.org!nntp.eternal-september.org!.POSTED!not-for-mail From: Keith Thompson Newsgroups: comp.lang.c Subject: Re: srand(0) Date: Tue, 23 Dec 2025 02:16:39 -0800 Organization: None to speak of Lines: 33 Message-ID: <875x9xwliw.fsf@example.invalid> References: <10ib0ka$3cgil$1@dont-email.me> <10ibava$2sora$1@dont-email.me> <10ibcub$25ihi$2@dont-email.me> <10idg3i$3k87$2@dont-email.me> MIME-Version: 1.0 Content-Type: text/plain Injection-Date: Tue, 23 Dec 2025 10:16:40 +0000 (UTC) Injection-Info: dont-email.me; posting-host="d1fb51fc7568455f75f8bb8a05d35bff"; logging-data="199134"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+kWjMvtGWAQWywlK9gZ41D" User-Agent: Gnus/5.13 (Gnus v5.13) Cancel-Lock: sha1:BGpGUkYbudsjp+DxGk3Ejc2dbsg= sha1:zOb0YMGcl/6W8g7OckMxYoP1BJA= Xref: csiph.com comp.lang.c:395907 Michael Sanders writes: > On Mon, 22 Dec 2025 13:18:19 +0100, Janis Papanagnou wrote: >> There's number sequence generators that produce 0 sequences if seeded >> with 0. And maybe the comment in 'man 3 rand', "If no seed value is >> provided, the rand() function is automatically seeded with a value >> of 1.", may have fostered his doubt. > > Janis - naive question for you... > > How do I bring up *posix only* man pages using 3? > > I see no difference when invoking any of: > > man 3 srand > or: man 3 posix srand > or: man posix 3 srand > > What I'm doing wrong here? On Debian, Ubuntu, and similar systems, you can install the "manpages-posix" (section 1) and "manpages-posix-dev" (sections 3 and 7) packages. You can then view the POSIX man page for srand by typing any of: man 3posix srand man -s 3posix srand man srand.3posix I'd expect similar packages to be available on (some) other systems. -- Keith Thompson (The_Other_Keith) Keith.S.Thompson+u@gmail.com void Void(void) { Void(); } /* The recursive call of the void */