code: public void markVisited(int loc) {
      if (checkBounds(loc)) {
        if (ZERO == this.registry[loc]) {
          this.unvisitedCount--;
        }
        this.registry[loc] = ONE;
      }
      else {
        throw new RuntimeException(
            "The location " + loc + " out of bounds [0," + (this.registry.length - 1) + "]");
      }
    }
docs: Marks location visited. If it was unvisited, counter decremented.
  
  @param loc The location to mark.