Advanced Search

Browse by Discipline

Scientific Societies

E-print Alerts

Add E-prints

E-print Network

  Advanced Search  

PREPRINT. In Proc. 27th ACM Symposium on Theory of Computing,pages 417426. ACM Press, 1995.

Summary: PREPRINT. In Proc. 27th ACM Symposium on Theory of
Computing,pages 417­426. ACM Press, 1995.
A tight lower bound for searching a sorted array
Arne Andersson \Lambda Johan Hšastad y Ola Petersson \Lambdaz
We show that given a k­character query string and an ar­
ray of n strings arranged in alphabetical order, finding a
matching string or report that no such string exists requires
k log log n
log log (4 + k log log n
log n )
+ k + log n
character comparisons in the worst case, which is tight.
1 Introduction
The problem of searching a sorted set of strings is indeed
fundamental. We assume that the strings are given in (lex­
icographically) sorted order in an array and that no extra


Source: Andersson, Arne - Department of Information Technology, Uppsala Universitet


Collections: Computer Technologies and Information Sciences