code: public void markVisited(int from, int upTo) {
      if (checkBounds(from) && checkBounds(upTo - 1)) {
        for (int i = from; i < upTo; i++) {
          this.markVisited(i);
        }
      }
      else {
        throw new RuntimeException("The location " + from + "," + upTo + " out of bounds [0,"
            + (this.registry.length - 1) + "]");
      }
    }
docs: Marks as visited a range of locations.
  
  @param from the start of labeling (inclusive).
  @param upTo the end of labeling (exclusive).