3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $xy = microtime(true); $n = 10000; while (--$n) { $a = 42; } // multiplication and formatting do not count as they go after the subtraction echo ("\nExecution took: " . number_format((microtime(true) - $xy) * 1000000, 0, '.', '') . " microsecond(s).\n");
Output for 5.6.16, 7.1.0
Execution took: 180 microsecond(s).
Output for 7.0.14
Execution took: 186 microsecond(s).
Output for 7.0.6
Execution took: 172 microsecond(s).
Output for 7.0.5
Execution took: 107 microsecond(s).
Output for 7.0.4
Execution took: 150 microsecond(s).
Output for 7.0.3
Execution took: 108 microsecond(s).
Output for 7.0.2
Execution took: 97 microsecond(s).
Output for 7.0.1
Execution took: 112 microsecond(s).
Output for 7.0.0
Execution took: 165 microsecond(s).
Output for 5.4.7, hhvm-3.12.0
Execution took: 229 microsecond(s).
Output for hhvm-3.10.0
Execution took: 389 microsecond(s).
Output for 5.5.24, 5.6.28
Execution took: 319 microsecond(s).
Output for 5.6.21
Execution took: 306 microsecond(s).
Output for 5.3.6, 5.6.20
Execution took: 277 microsecond(s).
Output for 5.6.18 - 5.6.19
Execution took: 217 microsecond(s).
Output for 5.6.17
Execution took: 190 microsecond(s).
Output for 5.4.1, 5.4.6, 5.6.15
Execution took: 191 microsecond(s).
Output for 5.6.14
Execution took: 336 microsecond(s).
Output for 5.4.39 - 5.4.40, 5.6.13
Execution took: 245 microsecond(s).
Output for 5.6.11 - 5.6.12
Execution took: 185 microsecond(s).
Output for 5.3.24, 5.6.10
Execution took: 290 microsecond(s).
Output for 5.4.30, 5.6.9
Execution took: 243 microsecond(s).
Output for 5.6.8
Execution took: 255 microsecond(s).
Output for 5.6.7
Execution took: 266 microsecond(s).
Output for 5.5.35
Execution took: 328 microsecond(s).
Output for 5.5.34
Execution took: 303 microsecond(s).
Output for 5.3.16, 5.5.27, 5.5.33
Execution took: 300 microsecond(s).
Output for 5.4.22, 5.5.32
Execution took: 231 microsecond(s).
Output for 5.5.31
Execution took: 241 microsecond(s).
Output for 5.5.30
Execution took: 316 microsecond(s).
Output for 5.5.29
Execution took: 288 microsecond(s).
Output for 5.5.28
Execution took: 183 microsecond(s).
Output for 5.4.0, 5.5.26
Execution took: 220 microsecond(s).
Output for 5.5.25
Execution took: 291 microsecond(s).
Output for 5.4.45
Execution took: 226 microsecond(s).
Output for 5.4.44
Execution took: 252 microsecond(s).
Output for 5.4.43
Execution took: 219 microsecond(s).
Output for 5.4.42
Execution took: 317 microsecond(s).
Output for 5.4.11, 5.4.41
Execution took: 230 microsecond(s).
Output for 5.4.38
Execution took: 480 microsecond(s).
Output for 5.4.37
Execution took: 1598 microsecond(s).
Output for 5.4.36
Execution took: 628 microsecond(s).
Output for 5.4.35
Execution took: 318 microsecond(s).
Output for 5.4.34
Execution took: 498 microsecond(s).
Output for 5.4.26, 5.4.32
Execution took: 223 microsecond(s).
Output for 5.4.31
Execution took: 354 microsecond(s).
Output for 5.4.29
Execution took: 209 microsecond(s).
Output for 5.4.28
Execution took: 212 microsecond(s).
Output for 5.4.15, 5.4.27
Execution took: 201 microsecond(s).
Output for 5.4.12, 5.4.24 - 5.4.25
Execution took: 192 microsecond(s).
Output for 5.4.23
Execution took: 200 microsecond(s).
Output for 5.4.21
Execution took: 311 microsecond(s).
Output for 5.4.20
Execution took: 204 microsecond(s).
Output for 5.4.19
Execution took: 239 microsecond(s).
Output for 5.4.4, 5.4.18
Execution took: 228 microsecond(s).
Output for 5.4.17
Execution took: 235 microsecond(s).
Output for 5.4.9, 5.4.16
Execution took: 199 microsecond(s).
Output for 5.4.14
Execution took: 197 microsecond(s).
Output for 5.4.13
Execution took: 275 microsecond(s).
Output for 5.4.10
Execution took: 205 microsecond(s).
Output for 5.4.8
Execution took: 193 microsecond(s).
Output for 5.4.5
Execution took: 210 microsecond(s).
Output for 5.4.3
Execution took: 236 microsecond(s).
Output for 5.4.2
Execution took: 184 microsecond(s).
Output for 5.3.29
Execution took: 281 microsecond(s).
Output for 5.3.28
Execution took: 269 microsecond(s).
Output for 5.3.27
Execution took: 267 microsecond(s).
Output for 5.3.26
Execution took: 263 microsecond(s).
Output for 5.3.25
Execution took: 366 microsecond(s).
Output for 5.3.23
Execution took: 388 microsecond(s).
Output for 5.3.22
Execution took: 421 microsecond(s).
Output for 5.3.21
Execution took: 570 microsecond(s).
Output for 5.3.20
Execution took: 390 microsecond(s).
Output for 5.3.19
Execution took: 411 microsecond(s).
Output for 5.3.18
Execution took: 412 microsecond(s).
Output for 5.3.17
Execution took: 420 microsecond(s).
Output for 5.3.15
Execution took: 295 microsecond(s).
Output for 5.3.14
Execution took: 262 microsecond(s).
Output for 5.3.13
Execution took: 280 microsecond(s).
Output for 5.3.12
Execution took: 446 microsecond(s).
Output for 5.3.11
Execution took: 463 microsecond(s).
Output for 5.3.10
Execution took: 313 microsecond(s).
Output for 5.3.9
Execution took: 276 microsecond(s).
Output for 5.3.8
Execution took: 310 microsecond(s).
Output for 5.3.7
Execution took: 294 microsecond(s).
Output for 5.3.5
Execution took: 268 microsecond(s).
Output for 5.3.4
Execution took: 297 microsecond(s).
Output for 5.3.3
Execution took: 292 microsecond(s).
Output for 5.3.2
Execution took: 332 microsecond(s).
Output for 5.3.1
Execution took: 320 microsecond(s).
Output for 5.3.0
Execution took: 477 microsecond(s).
Output for 5.2.17
Execution took: 597 microsecond(s).
Output for 5.2.16
Execution took: 673 microsecond(s).
Output for 5.2.15
Execution took: 678 microsecond(s).
Output for 5.2.14
Execution took: 634 microsecond(s).
Output for 5.2.13
Execution took: 604 microsecond(s).
Output for 5.2.12
Execution took: 383 microsecond(s).
Output for 5.2.11
Execution took: 615 microsecond(s).
Output for 5.2.10
Execution took: 345 microsecond(s).
Output for 5.2.9
Execution took: 403 microsecond(s).
Output for 5.2.8
Execution took: 352 microsecond(s).
Output for 5.2.7
Execution took: 364 microsecond(s).
Output for 5.2.6
Execution took: 357 microsecond(s).
Output for 5.2.5
Execution took: 518 microsecond(s).
Output for 5.2.4
Execution took: 742 microsecond(s).
Output for 5.2.3
Execution took: 694 microsecond(s).
Output for 5.2.2
Execution took: 607 microsecond(s).
Output for 5.2.1
Execution took: 344 microsecond(s).
Output for 5.2.0
Execution took: 520 microsecond(s).
Output for 5.1.6
Execution took: 617 microsecond(s).
Output for 5.1.5
Execution took: 369 microsecond(s).
Output for 5.1.4
Execution took: 551 microsecond(s).
Output for 5.1.3
Execution took: 368 microsecond(s).
Output for 5.1.2
Execution took: 423 microsecond(s).
Output for 5.1.1
Execution took: 602 microsecond(s).
Output for 5.1.0
Execution took: 362 microsecond(s).
Output for 5.0.5
Execution took: 1180 microsecond(s).
Output for 5.0.4
Execution took: 951 microsecond(s).
Output for 5.0.3
Execution took: 942 microsecond(s).
Output for 5.0.2
Execution took: 976 microsecond(s).
Output for 5.0.1
Execution took: 1900 microsecond(s).
Output for 5.0.0
Execution took: 2042 microsecond(s).
Output for 4.4.9
Execution took: 1469 microsecond(s).
Output for 4.4.8
Execution took: 986 microsecond(s).
Output for 4.4.7
Execution took: 1713 microsecond(s).
Output for 4.4.6
Execution took: 1208 microsecond(s).
Output for 4.4.5
Execution took: 1167 microsecond(s).
Output for 4.4.4
Execution took: 1677 microsecond(s).
Output for 4.4.3
Execution took: 1643 microsecond(s).
Output for 4.4.2
Execution took: 2516 microsecond(s).
Output for 4.4.1
Execution took: 1991 microsecond(s).
Output for 4.4.0
Execution took: 1160 microsecond(s).
Output for 4.3.11
Execution took: 1176 microsecond(s).
Output for 4.3.10
Execution took: 1855 microsecond(s).
Output for 4.3.9
Execution took: 1778 microsecond(s).
Output for 4.3.8
Execution took: 1008 microsecond(s).
Output for 4.3.7
Execution took: 992 microsecond(s).
Output for 4.3.6
Execution took: 1688 microsecond(s).
Output for 4.3.5
Execution took: 1638 microsecond(s).
Output for 4.3.4
Execution took: 989 microsecond(s).
Output for 4.3.3
Execution took: 988 microsecond(s).
Output for 4.3.2
Execution took: 1091 microsecond(s).
Output for 4.3.1
Execution took: 1007 microsecond(s).
Output for 4.3.0
Execution took: 947 microsecond(s).