code: private void computeLast() {
          for (int k = 0; k < last.length; k++) {
              last[k] = -1;
          }
          for (int j = pattern.length()-1; j >= 0; j--) {
              if (last[pattern.charAt(j)] < 0) {
                  last[pattern.charAt(j)] = j;
              }
          }
      }
docs: Computes the function <i>last</i> and stores its values in the array <code>last</code>.
  The function is defined as follows:
  <pre>
  last(Char ch) = the index of the right-most occurrence of the character ch
  in the pattern;
  -1 if ch does not occur in the pattern.
  </pre>
  The running time is O(pattern.length() + |Alphabet|).