3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $count = 50; $start = microtime(true); $code = ' $ret = ""; for ($i=0; $i<100; $i++) { $ret.= md5($i.$ret); } return $ret; '; for($i = 0; $i < $count; $i++) { eval($code); } printf("#1, done in %f\n", microtime(true) - $start); $start = microtime(true); $f = function() { // return ++$y; $ret = ''; for ($i=0; $i<100; $i++) { $ret.= md5($i.$ret); } return $ret; }; for($i = 0; $i < $count; $i++) { $f(); } printf("#2, done in %f\n", microtime(true) - $start); ?>
Output for 7.1.0
#1, done in 0.000453 #2, done in 0.021101
Output for 7.0.14
#1, done in 0.000469 #2, done in 0.021868
Output for 7.0.6
#1, done in 0.000406 #2, done in 0.017465
Output for 7.0.5
#1, done in 0.000503 #2, done in 0.021272
Output for 7.0.4
#1, done in 0.000423 #2, done in 0.019432
Output for 7.0.3
#1, done in 0.000305 #2, done in 0.013867
Output for 7.0.2
#1, done in 0.000342 #2, done in 0.015659
Output for 7.0.1
#1, done in 0.000351 #2, done in 0.015939
Output for 7.0.0
#1, done in 0.000446 #2, done in 0.020248
Output for hhvm-3.12.0
#1, done in 0.001334 #2, done in 0.023539
Output for hhvm-3.10.0

Process exited with code 153.
Output for 5.6.28
#1, done in 0.000550 #2, done in 0.023855
Output for 5.6.21
#1, done in 0.000511 #2, done in 0.022781
Output for 5.6.20
#1, done in 0.000488 #2, done in 0.022293
Output for 5.6.19
#1, done in 0.000484 #2, done in 0.021462
Output for 5.6.18
#1, done in 0.000448 #2, done in 0.020529
Output for 5.6.17
#1, done in 0.000453 #2, done in 0.020195
Output for 5.6.16
#1, done in 0.000368 #2, done in 0.016524
Output for 5.6.15
#1, done in 0.000305 #2, done in 0.014228
Output for 5.6.14
#1, done in 0.000494 #2, done in 0.022366
Output for 5.6.13
#1, done in 0.000512 #2, done in 0.022858
Output for 5.6.12
#1, done in 0.000313 #2, done in 0.014722
Output for 5.6.11
#1, done in 0.000313 #2, done in 0.014243
Output for 5.6.10
#1, done in 0.000497 #2, done in 0.020418
Output for 5.6.9
#1, done in 0.000536 #2, done in 0.022288
Output for 5.6.8
#1, done in 0.000305 #2, done in 0.014421
Output for 5.6.7
#1, done in 0.000275 #2, done in 0.012160
Output for 5.5.35
#1, done in 0.000487 #2, done in 0.021830
Output for 5.5.34
#1, done in 0.000332 #2, done in 0.015848
Output for 5.5.33
#1, done in 0.000463 #2, done in 0.021045
Output for 5.5.32
#1, done in 0.000448 #2, done in 0.020358
Output for 5.5.31
#1, done in 0.000454 #2, done in 0.019811
Output for 5.5.30
#1, done in 0.000604 #2, done in 0.020779
Output for 5.5.29
#1, done in 0.000323 #2, done in 0.014736
Output for 5.5.28
#1, done in 0.000381 #2, done in 0.017521
Output for 5.5.27
#1, done in 0.000370 #2, done in 0.016638
Output for 5.5.26
#1, done in 0.000344 #2, done in 0.015832
Output for 5.5.25
#1, done in 0.000381 #2, done in 0.017179
Output for 5.5.24
#1, done in 0.000465 #2, done in 0.020902
Output for 5.4.45
#1, done in 0.000473 #2, done in 0.020254
Output for 5.4.44
#1, done in 0.000518 #2, done in 0.019994
Output for 5.4.43
#1, done in 0.000433 #2, done in 0.019687
Output for 5.4.42
#1, done in 0.000430 #2, done in 0.024001
Output for 5.4.41
#1, done in 0.001145 #2, done in 0.022575
Output for 5.4.40
#1, done in 0.000462 #2, done in 0.020932
Output for 5.4.39
#1, done in 0.000510 #2, done in 0.023700
Output for 5.4.38
#1, done in 0.000445 #2, done in 0.020813
Output for 5.4.37
#1, done in 0.000472 #2, done in 0.021224
Output for 5.4.36
#1, done in 0.000453 #2, done in 0.020362
Output for 5.4.35
#1, done in 0.000371 #2, done in 0.043779
Output for 5.4.34
#1, done in 0.000377 #2, done in 0.017234
Output for 5.4.32
#1, done in 0.000340 #2, done in 0.014678
Output for 5.4.31
#1, done in 0.000305 #2, done in 0.014739
Output for 5.4.30
#1, done in 0.000358 #2, done in 0.015433
Output for 5.4.29
#1, done in 0.000336 #2, done in 0.015418
Output for 5.4.28
#1, done in 0.000789 #2, done in 0.017291
Output for 5.4.27
#1, done in 0.000307 #2, done in 0.014517
Output for 5.4.26
#1, done in 0.000317 #2, done in 0.014753
Output for 5.4.25
#1, done in 0.000353 #2, done in 0.015759
Output for 5.4.24
#1, done in 0.000357 #2, done in 0.017687
Output for 5.4.23
#1, done in 0.000317 #2, done in 0.015799
Output for 5.4.22
#1, done in 0.000348 #2, done in 0.015604
Output for 5.4.21
#1, done in 0.000436 #2, done in 0.018287
Output for 5.4.20
#1, done in 0.000316 #2, done in 0.015389
Output for 5.4.19
#1, done in 0.000370 #2, done in 0.017644
Output for 5.4.18
#1, done in 0.000328 #2, done in 0.017004
Output for 5.4.17
#1, done in 0.000405 #2, done in 0.030640
Output for 5.4.16
#1, done in 0.000354 #2, done in 0.016015
Output for 5.4.15
#1, done in 0.000361 #2, done in 0.016091
Output for 5.4.14
#1, done in 0.000436 #2, done in 0.019426
Output for 5.4.13
#1, done in 0.000457 #2, done in 0.017367
Output for 5.4.12
#1, done in 0.000339 #2, done in 0.015204
Output for 5.4.11
#1, done in 0.000324 #2, done in 0.015452
Output for 5.4.10
#1, done in 0.000394 #2, done in 0.017478
Output for 5.4.9
#1, done in 0.000356 #2, done in 0.016859
Output for 5.4.8
#1, done in 0.000359 #2, done in 0.016075
Output for 5.4.7
#1, done in 0.000341 #2, done in 0.015910
Output for 5.4.6
#1, done in 0.000390 #2, done in 0.018007
Output for 5.4.5
#1, done in 0.000370 #2, done in 0.016315
Output for 5.4.4
#1, done in 0.000366 #2, done in 0.016549
Output for 5.4.3
#1, done in 0.000352 #2, done in 0.015974
Output for 5.4.2
#1, done in 0.000363 #2, done in 0.016040
Output for 5.4.1
#1, done in 0.000367 #2, done in 0.016069
Output for 5.4.0
#1, done in 0.000345 #2, done in 0.015124
Output for 5.3.29
#1, done in 0.000323 #2, done in 0.015744
Output for 5.3.28
#1, done in 0.000348 #2, done in 0.015757
Output for 5.3.27
#1, done in 0.000378 #2, done in 0.015956
Output for 5.3.26
#1, done in 0.000342 #2, done in 0.015914
Output for 5.3.25
#1, done in 0.000352 #2, done in 0.016031
Output for 5.3.24
#1, done in 0.000353 #2, done in 0.016025
Output for 5.3.23
#1, done in 0.000352 #2, done in 0.016911
Output for 5.3.22
#1, done in 0.000449 #2, done in 0.019410
Output for 5.3.21
#1, done in 0.000414 #2, done in 0.018731
Output for 5.3.20
#1, done in 0.000385 #2, done in 0.018629
Output for 5.3.19
#1, done in 0.000445 #2, done in 0.018710
Output for 5.3.18
#1, done in 0.000480 #2, done in 0.029020
Output for 5.3.17
#1, done in 0.000374 #2, done in 0.015688
Output for 5.3.16
#1, done in 0.000412 #2, done in 0.019207
Output for 5.3.15
#1, done in 0.000349 #2, done in 0.016581
Output for 5.3.14
#1, done in 0.000341 #2, done in 0.016160
Output for 5.3.13
#1, done in 0.000346 #2, done in 0.015364
Output for 5.3.12
#1, done in 0.000406 #2, done in 0.018871
Output for 5.3.11
#1, done in 0.000393 #2, done in 0.018912
Output for 5.3.10
#1, done in 0.000429 #2, done in 0.019458
Output for 5.3.9
#1, done in 0.000504 #2, done in 0.018667
Output for 5.3.8
#1, done in 0.000426 #2, done in 0.020158
Output for 5.3.7
#1, done in 0.000340 #2, done in 0.016084
Output for 5.3.6
#1, done in 0.000358 #2, done in 0.015328
Output for 5.3.5
#1, done in 0.000328 #2, done in 0.015132
Output for 5.3.4
#1, done in 0.000373 #2, done in 0.015487
Output for 5.3.3
#1, done in 0.000331 #2, done in 0.015362
Output for 5.3.2
#1, done in 0.000347 #2, done in 0.015828
Output for 5.3.1
#1, done in 0.000342 #2, done in 0.015700
Output for 5.3.0
#1, done in 0.000343 #2, done in 0.015908
Output for 4.4.2 - 4.4.9, 5.1.0 - 5.2.17
Parse error: syntax error, unexpected T_FUNCTION in /in/uV05h on line 20
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 T_FUNCTION in /in/uV05h on line 20
Process exited with code 255.
Output for 4.3.2 - 4.3.4
Parse error: parse error in /in/uV05h on line 20
Process exited with code 255.