We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7f7a7c5 commit 80e1d29Copy full SHA for 80e1d29
other/combinations.pl
@@ -0,0 +1,6 @@
1
+use v6;
2
+
3
+multi combs(@, 0) { "" };
4
+multi combs { combs(@^dict, $^n - 1) X~ @dict };
5
6
+(.say for combs(<a b c>, $_)) for 1..4;
0 commit comments