docs: private static int follow(int i, int[] partitions) {
      int next = partitions[i], tmp;
      while(i != next) {
        tmp = next;
        next = partitions[i] = partitions[next];
        i = tmp;
      }
      return i;
    }