A piggy bank of commands, fixes, succinct reviews, some mini articles and technical opinions from a (mostly) Perl developer.

Combinations, permuations and iterations

To generate all combinations or permutations of a fixed list, use Math::Combinatorics

To generate sequential values for a set of slots, e.g. all binary numbers, or the number of 'max_results' for several modules do this:

  1. add one to the first slot
  2. if that takes it over the maximum, set it to zero and add one to the next slot
  3. repeat step 2 until you reach all zeroes
  4. if all zeroes, you are finished.