Permutations with Repetition


Example: Number of possible combinations to a combination lock. (Order does matter.)

Preview of this algorithm

Icon Variable
Ask for n with default 1
Icon Output
Print text n = number of items per column
Icon Variable
Ask for t with default 0
Icon Output
Print text t = number of columns
Icon Output
Print text "n" ^ "t"
Icon Variable
Set r to n ^ t
Icon Output
Print variable r