PRIMES(6)                     NetBSD Games Manual                    PRIMES(6)

     primes -- generate primes

     primes [-d] [start [stop]]

     The primes utility prints primes in ascending order, one per line, start-
     ing at or above start and continuing until, but not including stop.  The
     start value must be at least 0 and not greater than stop.  The stop value
     must not be greater than 4294967295.  The default value of stop is

     When the primes utility is invoked with no arguments, start is read from
     standard input.  stop is taken to be 4294967295.  The start value may be
     preceded by a single `+'.  The start value is terminated by a non-digit
     character (such as a newline).  The input line must not be longer than
     255 characters.  When given the -d argument, primes prints the difference
     between the current and the previous prime.

     Out of range or invalid input results in an appropriate error message
     being written to standard error.

     primes won't get you a world record.

NetBSD 7.0                     February 3, 2008                     NetBSD 7.0

You can also request any man page by name and (optionally) by section:


Use the DEFAULT collection to view manual pages for third-party software.

©1994 Man-cgi 1.15, Panagiotis Christias <>
©1996-2014 Modified for NetBSD by Kimmo Suominen