// output of ./demo/graph/graph-perm-pref-rev-demo.cc: // Description: //% Permutations by prefix reversals. arg 1: 4 == n [Permutations of n elements] default=4 arg 2: 1 == maxnp [stop after maxnp paths (0: never stop)] default=1 0: 0: 0: [ 0 1 2 3 ] 1: 1: [ 1 0 2 3 ] 2 2: 2: [ 2 0 1 3 ] 3 3: 4: [ 0 2 1 3 ] 2 4: 5: [ 1 2 0 3 ] 3 5: 6: [ 2 1 0 3 ] 2 6: 3: [ 3 0 1 2 ] 4 7: 8: [ 0 3 1 2 ] 2 8: 9: [ 1 3 0 2 ] 3 9: 7: [ 3 1 0 2 ] 2 10: 12: [ 0 1 3 2 ] 3 11: 13: [ 1 0 3 2 ] 2 12: 10: [ 2 3 0 1 ] 4 13: 11: [ 3 2 0 1 ] 2 14: 16: [ 0 2 3 1 ] 3 15: 14: [ 2 0 3 1 ] 2 16: 15: [ 3 0 2 1 ] 3 17: 20: [ 0 3 2 1 ] 2 18: 17: [ 1 2 3 0 ] 4 19: 18: [ 2 1 3 0 ] 2 20: 19: [ 3 1 2 0 ] 3 21: 21: [ 1 3 2 0 ] 2 22: 22: [ 2 3 1 0 ] 3 23: 23: [ 3 2 1 0 ] 2 n = 4 #pfct = 1 #paths = 1 #cycles = 1