Added termios.h
[unix-history] / usr / src / games / primes / primes.h
CommitLineData
d1ff48a1
KB
1/*
2 * Copyright (c) 1989 The Regents of the University of California.
3 * All rights reserved.
4 *
5 * This code is derived from software contributed to Berkeley by
6 * Landon Curt Noll.
7 *
abde58c2 8 * %sccs.include.redist.c%
d1ff48a1 9 *
abde58c2 10 * @(#)primes.h 5.2 (Berkeley) %G%
d1ff48a1
KB
11 */
12
13/*
14 * primes - generate a table of primes between two values
15 *
16 * By: Landon Curt Noll chongo@toad.com, ...!{sun,tolsoft}!hoptoad!chongo
17 *
18 * chongo <for a good prime call: 391581 * 2^216193 - 1> /\oo/\
19 */
20
21/* ubig is the type that holds a large unsigned value */
22typedef unsigned long ubig; /* must be >=32 bit unsigned value */
23
24/*
25 * sieve parameters
26 */
27#define BIG ((ubig)0xffffffff) /* highest value we will sieve */
28#define SEMIBIG ((ubig)0x7fffffff) /* highest signed value */
29#define NEG_SEMIBIG ((ubig)0x80000000) /* lowest signed value */
30#define TABSIZE 256*1024 /* bytes in sieve table (must be > 3*5*7*11) */