1

I've been working on implementing the Boyer-Moore algorithm in Java and I've hit a problem. The document (http://www.cs.utexas.edu/~moore/publications/fstrpos.pdf) shows two examples for delta2(j) tables. The program I have made correctly calculates all the delta values, except delta(2) (the first B). My program claims that delta(2) is 2 (and that rpr(2) is 8). I have done the work on paper and it appears that this calculation is correct, but it disagrees with the document.

I am fairly certain that the document doesn't have a mistake so does anyone know if I have done something wrong.

4

0 回答 0