3v4l.org

run code in 300+ PHP versions simultaneously
<?php function createAttributeCollections($pricingAttributes = null, $permutation = array()){ //permutation result if (empty($pricingAttributes)) { echo implode(',', $permutation ).'<br>'; //permutation } else { //permutation loop for ($i = count($pricingAttributes) - 1; $i >= 0; --$i) { $newpricingAttributes = $pricingAttributes; $newPermutations = $permutation; list($foo) = array_splice($newpricingAttributes, $i, 1); array_unshift($newPermutations, $foo); createAttributeCollections($newpricingAttributes, $newPermutations); } } } $results = createAttributeCollections(array('A','B','G','U'));
Output for git.master, git.master_jit, rfc.property-hooks
A,B,G,U<br>B,A,G,U<br>A,G,B,U<br>G,A,B,U<br>B,G,A,U<br>G,B,A,U<br>A,B,U,G<br>B,A,U,G<br>A,U,B,G<br>U,A,B,G<br>B,U,A,G<br>U,B,A,G<br>A,G,U,B<br>G,A,U,B<br>A,U,G,B<br>U,A,G,B<br>G,U,A,B<br>U,G,A,B<br>B,G,U,A<br>G,B,U,A<br>B,U,G,A<br>U,B,G,A<br>G,U,B,A<br>U,G,B,A<br>

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
58.48 ms | 402 KiB | 8 Q