code: public boolean isVisited(int from, int upTo) {
      if (checkBounds(from) && checkBounds(upTo - 1)) {
        // perform the visit check
        //
        for (int i = from; i < upTo; i++) {
          if (ONE == this.registry[i]) {
            return true;
          }
        }
        return false;
      }
      else {
        throw new RuntimeException("The location " + from + "," + upTo + " out of bounds [0,"
            + (this.registry.length - 1) + "]");
      }
    }
docs: Check if the interval and its boundaries were visited.
  
  @param from The interval start (inclusive).
  @param upTo The interval end (exclusive).
  @return True if visited.