A cross-bifix-free code of length is a set of words of length
such that no nonempty proper prefix of
any codeword equals a suffix of any codeword,
including itself. Such codes can be used to distinguish
true codeword boundaries from incidental matches across
a boundary (Chee et al. 2013).
For a related two-family problem, let and
be sets of words of length
over an alphabet of size
. Require that no nonempty suffix of any word
in
equal a prefix of a word in
, including a possible overlap
of length
. Zakharov (2026) proved the bound
The last bound is asymptotically sharp when the alphabet size is allowed to vary with . Yoo (2026) registered a Lean formalization of the
last inequality for the product of cardinalities.