Comparing Perl scripts

From Carls wiki

Jump to: navigation, search

Johan and I (Carl) plan to write one Perl script each for doing a specific task, and then compare them, just to see how different two solutions to the same problem can be in Perl.

Necklaces

From the "Discrete mathematics", 2ed by Norman L Biggs, p 289:

Necklaces are manufactured by arranging 13 white beads and three black beads on a loop of string. how many different necklaces can be produced in this way? (The position of the fastening may be ignored.)

I have already written a solution, and Johan tells me that he has designed his.