3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $css1 = ''; $time = microtime(true); for($i = 0; $i < 100000; $i++) { $css1 .= sprintf('foo %d', $i); } $time = microtime(true) - $time; echo number_format($time, 3) . 's'; $css2 = ''; $time = microtime(true); for($i = 0; $i < 100000; $i++) { $css2[] = sprintf('foo %d', $i); } $time = microtime(true) - $time; $css3 = implode('', $css2); echo number_format($time, 3) . 's';
Output for 7.1.0
0.014s Fatal error: Uncaught Error: [] operator not supported for strings in /in/KsLAD:14 Stack trace: #0 {main} thrown in /in/KsLAD on line 14
Process exited with code 255.
Output for 7.0.14
0.013s0.016s
Output for 7.0.6
0.013s0.025s
Output for 7.0.5
0.012s0.020s
Output for 7.0.0, 7.0.4
0.008s0.012s
Output for 7.0.3
0.011s0.024s
Output for 7.0.2
0.011s0.022s
Output for 7.0.1
0.013s0.018s
Output for hhvm-3.12.0
0.072s
Process exited with code 137.
Output for hhvm-3.10.0
0.024s0.035s
Output for 5.6.28
0.036s0.054s
Output for 5.6.11, 5.6.21
0.025s0.043s
Output for 5.4.18, 5.6.20
0.024s0.040s
Output for 5.6.19
0.018s0.034s
Output for 5.4.19, 5.5.27, 5.6.18
0.023s0.040s
Output for 5.6.17
0.021s0.039s
Output for 5.4.26 - 5.4.27, 5.6.16
0.022s0.039s
Output for 5.3.11, 5.6.15
0.026s0.047s
Output for 5.5.35, 5.6.14
0.019s0.036s
Output for 5.6.13
0.027s0.044s
Output for 5.6.12
0.024s0.037s
Output for 5.4.5, 5.6.10
0.025s0.040s
Output for 5.6.9
0.021s0.037s
Output for 5.3.19, 5.6.8
0.027s0.046s
Output for 5.2.1, 5.2.6, 5.3.17, 5.5.34
0.029s0.047s
Output for 5.5.33
0.024s0.039s
Output for 5.5.29, 5.5.32
0.020s0.037s
Output for 5.5.31
0.026s0.043s
Output for 5.5.30
0.027s0.055s
Output for 5.4.17, 5.5.28
0.022s0.040s
Output for 5.5.26
0.032s0.047s
Output for 5.5.25
0.021s0.043s
Output for 5.5.24
0.022s0.038s
Output for 5.4.45
0.032s0.034s
Output for 5.4.44
0.056s0.055s
Output for 5.4.43
0.031s0.096s
Output for 5.4.42
0.035s0.054s
Output for 5.4.41
0.043s0.051s
Output for 5.4.40
0.051s0.154s
Output for 5.4.39
0.025s0.032s
Output for 5.4.38
0.054s0.107s
Output for 5.4.37
0.032s0.086s
Output for 5.4.36
0.064s0.167s
Output for 5.4.35
0.034s0.160s
Output for 5.4.34
0.033s0.077s
Output for 5.4.32
0.029s0.041s
Output for 5.4.31
0.026s0.039s
Output for 5.4.30
0.023s0.041s
Output for 5.4.29
0.023s0.039s
Output for 5.4.9, 5.4.28
0.024s0.043s
Output for 5.4.25
0.023s0.042s
Output for 5.2.15, 5.4.24
0.027s0.071s
Output for 5.4.23
0.028s0.049s
Output for 5.4.22
0.025s0.049s
Output for 5.3.10, 5.4.21
0.029s0.046s
Output for 5.4.20
0.024s0.041s
Output for 5.4.16
0.024s0.045s
Output for 5.4.15
0.023s0.045s
Output for 5.4.14
0.031s0.052s
Output for 5.3.3, 5.4.13
0.024s0.044s
Output for 5.4.11 - 5.4.12
0.022s0.041s
Output for 5.4.10
0.024s0.053s
Output for 5.4.7 - 5.4.8
0.023s0.044s
Output for 5.4.6
0.026s0.048s
Output for 5.4.1, 5.4.4
0.023s0.043s
Output for 5.4.3
0.031s0.046s
Output for 5.4.2
0.024s0.049s
Output for 5.4.0
0.022s0.043s
Output for 5.3.22, 5.3.29
0.025s0.045s
Output for 5.3.28
0.026s0.050s
Output for 5.3.15, 5.3.20, 5.3.27
0.028s0.047s
Output for 5.3.26
0.026s0.044s
Output for 5.3.25
0.026s0.054s
Output for 5.3.24
0.028s0.045s
Output for 5.3.23
0.025s0.046s
Output for 5.3.21
0.028s0.048s
Output for 5.3.18
0.027s0.047s
Output for 5.2.12, 5.3.16
0.027s0.048s
Output for 5.3.14
0.030s0.052s
Output for 5.3.13
0.025s0.048s
Output for 5.3.12
0.032s0.049s
Output for 5.3.9
0.028s0.050s
Output for 5.3.8
0.030s0.058s
Output for 5.3.7
0.043s0.045s
Output for 5.3.6
0.024s0.048s
Output for 5.3.5
0.030s0.047s
Output for 5.3.4
0.027s0.045s
Output for 5.3.2
0.049s0.075s
Output for 5.3.1
0.026s0.052s
Output for 5.3.0
0.041s0.044s
Output for 5.2.17
0.035s0.052s
Output for 5.2.16
0.043s0.086s
Output for 5.2.14
0.039s0.087s
Output for 5.2.13
0.041s0.054s
Output for 5.2.11
0.033s0.060s
Output for 5.2.10
0.035s0.053s
Output for 5.2.9
0.041s0.090s
Output for 5.2.8
0.053s0.090s
Output for 5.2.7
0.061s0.127s
Output for 5.2.5
0.028s0.060s
Output for 5.2.4
0.030s0.060s
Output for 5.2.3
0.042s0.066s
Output for 5.2.2
0.042s0.054s
Output for 5.2.0
0.033s0.045s
Output for 5.1.6
0.030s0.059s
Output for 5.1.5
0.030s0.049s
Output for 5.1.4
0.031s0.051s
Output for 5.1.3
0.032s0.051s
Output for 5.1.2
0.042s0.055s
Output for 5.1.1
0.094s0.077s
Output for 5.1.0
0.036s0.052s
Output for 5.0.5
0.061s0.077s
Output for 5.0.4
0.074s0.071s
Output for 5.0.3
0.056s0.073s
Output for 5.0.2
0.119s0.137s
Output for 5.0.1
0.103s0.128s
Output for 5.0.0
0.085s0.098s
Output for 4.4.9
0.051s0.074s
Output for 4.3.0, 4.4.8
0.057s0.069s
Output for 4.4.7
0.052s0.074s
Output for 4.4.6
0.059s0.076s
Output for 4.4.5
0.054s0.068s
Output for 4.4.4
0.066s0.082s
Output for 4.4.3
0.051s0.093s
Output for 4.4.2
0.053s-0.929s
Output for 4.4.1
0.053s0.075s
Output for 4.4.0
0.070s0.083s
Output for 4.3.11
0.067s0.076s
Output for 4.3.10
0.056s0.082s
Output for 4.3.9
0.070s-0.924s
Output for 4.3.8
0.054s0.083s
Output for 4.3.7
0.066s0.078s
Output for 4.3.6
0.051s0.073s
Output for 4.3.5
0.051s0.081s
Output for 4.3.4
0.048s-0.931s
Output for 4.3.3
0.051s0.066s
Output for 4.3.2
0.050s0.114s
Output for 4.3.1
0.051s0.083s