3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php for($s=[a,d,h,s],$p=0;$p<4;$p++)for($c=1;$c<14;)$a[]=$s[$p].++$c;print_r($a);
Output for 5.4.0 - 5.6.28, hhvm-3.12.0, 7.0.0 - 7.1.0
Notice: Use of undefined constant a - assumed 'a' in /in/OGMcZ on line 1 Notice: Use of undefined constant d - assumed 'd' in /in/OGMcZ on line 1 Notice: Use of undefined constant h - assumed 'h' in /in/OGMcZ on line 1 Notice: Use of undefined constant s - assumed 's' in /in/OGMcZ on line 1 Array ( [0] => a2 [1] => a3 [2] => a4 [3] => a5 [4] => a6 [5] => a7 [6] => a8 [7] => a9 [8] => a10 [9] => a11 [10] => a12 [11] => a13 [12] => a14 [13] => d2 [14] => d3 [15] => d4 [16] => d5 [17] => d6 [18] => d7 [19] => d8 [20] => d9 [21] => d10 [22] => d11 [23] => d12 [24] => d13 [25] => d14 [26] => h2 [27] => h3 [28] => h4 [29] => h5 [30] => h6 [31] => h7 [32] => h8 [33] => h9 [34] => h10 [35] => h11 [36] => h12 [37] => h13 [38] => h14 [39] => s2 [40] => s3 [41] => s4 [42] => s5 [43] => s6 [44] => s7 [45] => s8 [46] => s9 [47] => s10 [48] => s11 [49] => s12 [50] => s13 [51] => s14 )
Output for hhvm-3.10.0

Process exited with code 153.
Output for 4.4.2 - 4.4.9, 5.1.0 - 5.3.29
Parse error: syntax error, unexpected '[' in /in/OGMcZ on line 1
Process exited with code 255.
Output for 4.3.0 - 4.3.1, 4.3.5 - 4.4.1, 5.0.0 - 5.0.5
Parse error: parse error, unexpected '[' in /in/OGMcZ on line 1
Process exited with code 255.
Output for 4.3.2 - 4.3.4
Parse error: parse error in /in/OGMcZ on line 1
Process exited with code 255.