Professional Documents
Culture Documents
1980 - Minimal Perfect Hash Functions Made Simple (P17-Cichelli)
1980 - Minimal Perfect Hash Functions Made Simple (P17-Cichelli)
Received May 1978; revised September 1978; accepted September 1979 Introduction
References
!. Bateman, C.R. Predicting performance in a basic computer In several recent articles [2, 3] it has been asserted
course. Proc. of the Fifth Annual Meeting of the Amer. Inst. for that in general computing minimal perfect hash functions
Decision Sciences, Boston, Mass., 1973. for static identifier lists (keys) is difficult. In [1], Knuth
2. Newstead, P.R. Grade and ability predictions in an introductory
programming course. SIGCSE Bull. 7, 2 (June 1975), pp. 87-91. also notes the difficulty in computing perfect hash func-
tions. He estimates that for the set of words used here in
Example No. 3 a search for such a function might include
the examination of 1043 possibilities. A program imple-
Permission to copy without fee all or part of this material is
granted provided that the copies are not made or distributed for direct
commercial advantage, the ACM copyright notice and the title of the
publication and its date appear, and notice is given that copying is by
permission of the Association for Computing Machinery. To copy
otherwise, or to republish, requires a fee and/or specific permission.
Author's present address: R.J. Cichelli, Software Consulting Ser-
vices, 901 Whittier Drive, Allentown, PA 18103.
© 1980 ACM 0001-0782/80/0100-0017 $00.75.
Example No. 2
The second example is for the list of Pascal's prede-
fined identifiers.
A = 15, B = 9 , C = II, D = 19, E = 5 , F = 3 , G = O , H = O , I = 3 ,
J = 0 , K = 16, L = 13, M = I . N = 19, O = 0 , P = 18, Q = 0 , R = 0 ,
S = 15, T = 0 , U = 17, V = 0 , W = 10, X = 0, Y = 0, Z = 0.
GET, TEXT, RESET, OUTPUT, MAX1NT, INPUT, TRUE, INTE-
GER, EOF, REWRITE, FALSE, CHR, CHAR, TRUNC, REAL,
SQR, SQRT, WRITE, PUT, ORD, READ, ROUND, READLN,
EXP, PAGE, EOLN, COS, SUCC, DISPOSE, NEW, ABS, LN,
BOOLEAN, WRITELN, SIN, PACK, UNPACK, ARCTAN, PRED.