Alteration factory.

Creates a alteration NFA for (at least) two NFA-fragments.
function alt(first, ...fragments) {
  for (let fragment of fragments) {
    first = altPair(first, fragment);
  }
  return first;
}