3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arrayTable = [ [1, 2, 3, 4, 5], [6, 7, 8, 9, 10], ]; $i = 0; $transpose = []; while ($columns = array_column($arrayTable, $i++)) { $transpose[] = $columns; } $rows = count($transpose); for ($i = 0; $i < $rows; $i++){ $cols = count($transpose[$i]); for ($j = 0; $j < $cols; $j++) { $table .= $transpose[$i][$j] . ','; } } echo $table;
Output for git.master, git.master_jit, rfc.property-hooks
Warning: Undefined variable $table in /in/6WBav on line 19 1,6,2,7,3,8,4,9,5,10,

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:
33.84 ms | 401 KiB | 8 Q