code: public <I, A extends MutableDeterministic<?, I, ?, ? super SP, ? super TP>> A generateICDeterministicAutomaton(int numStates,
                                                                                                                     Collection<? extends I> inputs,
                                                                                                                     A result,
                                                                                                                     Random r) {
          MutableDeterministic.StateIntAbstraction<I, ?, ? super SP, ? super TP> resultAbs = result.stateIntAbstraction();
  
          List<? extends I> inputsList = CollectionsUtil.randomAccessList(inputs);
  
          resultAbs.addIntInitialState(spSupplier.apply(r));
          for (int i = 1; i < numStates; i++) {
              int src, succ;
              I input;
              do {
                  src = r.nextInt(i);
                  input = RandomUtil.choose(inputsList, r);
                  succ = resultAbs.getSuccessor(src, input);
              } while (succ >= 0);
              int next = resultAbs.addIntState(spSupplier.apply(r));
              resultAbs.setTransition(src, input, next, tpSupplier.apply(r));
          }
  
          for (int i = 0; i < numStates; i++) {
              for (I input : inputs) {
                  if (resultAbs.getSuccessor(i, input) >= 0) {
                      continue;
                  }
                  int succ = r.nextInt(numStates);
                  resultAbs.setTransition(i, input, succ, tpSupplier.apply(r));
              }
          }
  
          return result;
      }
docs: Generates an initially connected (IC) deterministic automaton with the given parameters. Note that the automaton
  will <b>not</b> be minized.
  
  @param numStates
  the number of states of the resulting automaton
  @param inputs
  the input symbols to consider during generation
  @param result
  the result automaton (should be empty)
  @param r
  the randomness source
  
  @return the result automaton