3v4l.org

run code in 300+ PHP versions simultaneously
<?php class WoWAPI{ /* Sadly, since the WoW API uses the same domain as the public site, Websense blocks it. Even the API calls are blocked. :( But, for the WoW fans, when you get home, go to http://us.battle.net/api/wow/character/" + YourRealm + "/" + YourCharacterName and be amazed! */ const HOST = 'http://us.battle.net'; public function __call($name, $args) { $url = self::HOST . '/api/wow'; //strip off get_ if (substr($name, 0, 3) == 'get') { $name = substr($name, 3); if (substr($name, 0, 1) == '_') { $name = substr($name, 1); } } //Slice the command up, and append the args $command = array_merge(explode('_', $name), $args); //construct the URL foreach ($command as $segment) { $url .= strtolower("/$segment"); } //send the get request and return the body //For the WoW API, everything returns as a JSON string. return http_parse_message(http_get($url))->body; }}$wowApi = new WoWAPI;echo $wowApi->getData_character('races');

Here you find the average performance (time & memory) of each version. A grayed out version indicates it didn't complete successfully (based on exit-code).

VersionSystem time (s)User time (s)Memory (MiB)
5.4.310.0370.04019.11
5.4.300.0270.03319.16
5.4.290.0470.05719.22
5.4.280.0330.06719.13
5.4.270.0200.04019.08
5.4.260.0270.03319.17
5.4.250.0200.04019.25
5.4.240.0300.03319.20
5.4.230.0230.03719.08
5.4.220.0230.03718.91
5.4.210.0270.04019.26
5.4.200.0170.04319.21
5.4.190.0270.03318.97
5.4.180.0230.03318.94
5.4.170.0200.04319.15
5.4.160.0270.03019.11
5.4.150.0300.03018.93
5.4.140.0200.03716.42
5.4.130.0230.03316.38
5.4.120.0330.02716.43
5.4.110.0270.03316.45
5.4.100.0270.05316.48
5.4.90.0170.04016.50
5.4.80.0230.04016.55
5.4.70.0270.04016.36
5.4.60.0200.04716.61
5.4.50.0400.06316.30
5.4.40.0270.03316.50
5.4.30.0270.04016.29
5.4.20.0270.04316.60
5.4.10.0330.06716.43
5.4.00.0230.06715.82
5.3.280.0230.03714.64
5.3.270.0230.04314.49
5.3.260.0300.03714.76
5.3.250.0170.04314.65
5.3.240.0230.03314.61
5.3.230.0230.03714.65
5.3.220.0170.03714.60
5.3.210.0200.03714.57
5.3.200.0230.04014.56
5.3.190.0300.06014.62
5.3.180.0270.03314.60
5.3.170.0270.03314.62
5.3.160.0370.06014.59
5.3.150.0330.06714.57
5.3.140.0370.05714.58
5.3.130.0300.06314.54
5.3.120.0300.04014.57
5.3.110.0330.03314.54
5.3.100.0330.03014.19
5.3.90.0270.05014.03
5.3.80.0330.03313.91
5.3.70.0430.06014.06
5.3.60.0430.05014.00
5.3.50.0330.04713.95
5.3.40.0430.05713.84
5.3.30.0300.03713.83
5.3.20.0300.03713.66
5.3.10.0270.03713.65
5.3.00.0470.05713.64
5.2.170.0430.02311.30
5.2.160.0300.04311.15
5.2.150.0200.03311.30
5.2.140.0270.05011.29
5.2.130.0330.05311.05
5.2.120.0270.03011.14
5.2.110.0300.04011.04
5.2.100.0230.03311.10
5.2.90.0400.05011.10
5.2.80.0300.05711.01
5.2.70.0230.04011.13
5.2.60.0270.03311.06
5.2.50.0300.03311.07
5.2.40.0230.03310.95
5.2.30.0200.05311.03
5.2.20.0300.05310.98
5.2.10.0230.06010.86
5.2.00.0300.05010.77
5.1.60.0300.0579.98
5.1.50.0270.03710.05
5.1.40.0230.0239.96
5.1.30.0230.02710.25
5.1.20.0230.02310.34
5.1.10.0230.05010.09
5.1.00.0270.04010.12
5.0.50.0130.0238.59
5.0.40.0130.0308.48
5.0.30.0130.0338.29
5.0.20.0130.0278.20
5.0.10.0100.0278.26
5.0.00.0100.0308.22
4.4.90.0100.0337.83
4.4.80.0100.0177.83
4.4.70.0130.0277.83
4.4.60.0170.0137.83
4.4.50.0100.0307.83
4.4.40.0170.0337.83
4.4.30.0130.0337.83
4.4.20.0130.0337.83
4.4.10.0130.0377.83
4.4.00.0130.0507.83
4.3.110.0130.0177.83
4.3.100.0130.0237.83
4.3.90.0130.0177.83
4.3.80.0100.0507.83
4.3.70.0170.0137.83
4.3.60.0170.0207.83
4.3.50.0100.0377.83
4.3.40.0170.0337.83
4.3.30.0100.0307.83
4.3.20.0100.0237.83
4.3.10.0070.0337.83
4.3.00.0100.0237.83

preferences:
246.33 ms | 1394 KiB | 8 Q