3v4l.org

run code in 300+ PHP versions simultaneously
<?php $string = <<<STRING array ( 2 => 'authenticated user', 3 => 'administrator', 6 => 'employee', ) STRING; $string2 = var_export(array(2 => 'authenticated user', 3 => 'administrator', 6 => 'employee'), TRUE); eval('$foo = $string;'); eval('$bar = '$string2); var_dump($foo); var_dump($bar);

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.0200.03018.87
5.4.300.0100.04019.16
5.4.290.0130.04018.87
5.4.280.0200.03019.06
5.4.270.0170.04718.94
5.4.260.0170.03319.19
5.4.250.0100.04719.07
5.4.240.0200.04318.86
5.4.230.0130.03719.19
5.4.220.0170.03318.99
5.4.210.0130.03719.05
5.4.200.0170.03319.21
5.4.190.0170.04319.07
5.4.180.0200.03018.84
5.4.170.0230.03719.08
5.4.160.0100.04719.14
5.4.150.0170.05719.13
5.4.140.0230.06716.46
5.4.130.0100.05716.50
5.4.120.0170.04016.32
5.4.110.0270.05016.45
5.4.100.0170.08016.33
5.4.90.0200.06716.56
5.4.80.0300.05016.36
5.4.70.0300.05716.54
5.4.60.0230.07016.43
5.4.50.0230.07016.24
5.4.40.0270.06316.32
5.4.30.0200.07016.42
5.4.20.0230.06716.43
5.4.10.0230.04016.59
5.4.00.0130.03715.80
5.3.280.0130.03714.55
5.3.270.0130.03714.43
5.3.260.0100.04014.50
5.3.250.0230.04014.59
5.3.240.0130.06714.48
5.3.230.0100.04014.46
5.3.220.0100.06014.50
5.3.210.0170.04714.55
5.3.200.0230.07014.47
5.3.190.0270.03014.54
5.3.180.0230.05014.51
5.3.170.0300.06314.51
5.3.160.0300.06714.42
5.3.150.0230.05014.41
5.3.140.0230.07014.64
5.3.130.0330.06314.42
5.3.120.0300.07014.50
5.3.110.0170.05314.41
5.3.100.0270.06714.07
5.3.90.0270.07013.88
5.3.80.0300.06313.87
5.3.70.0170.05313.93
5.3.60.0200.07314.04
5.3.50.0270.05313.89
5.3.40.0170.04313.74
5.3.30.0170.07013.75
5.3.20.0170.07713.53
5.3.10.0200.05313.58
5.3.00.0230.06313.57
5.2.170.0170.03712.75
5.2.160.0130.02712.75
5.2.150.0130.06312.75
5.2.140.0170.06312.75
5.2.130.0170.03712.75
5.2.120.0070.06712.75
5.2.110.0200.05712.75
5.2.100.0170.06012.75
5.2.90.0230.03712.75
5.2.80.0170.06712.75
5.2.70.0170.05712.75
5.2.60.0200.05712.75
5.2.50.0200.03712.75
5.2.40.0170.06012.75
5.2.30.0130.06312.75
5.2.20.0200.04312.75
5.2.10.0100.04012.75
5.2.00.0100.03712.75
5.1.60.0270.01712.75
5.1.50.0200.05012.75
5.1.40.0130.05312.75
5.1.30.0070.05312.75
5.1.20.0200.05012.75
5.1.10.0100.05712.75
5.1.00.0170.04012.75
5.0.50.0030.05312.75
5.0.40.0070.02312.75
5.0.30.0200.03712.75
5.0.20.0070.04012.75
5.0.10.0130.02012.75
5.0.00.0070.03312.75
4.4.90.0070.03712.75
4.4.80.0070.03012.75
4.4.70.0070.01712.75
4.4.60.0100.01712.75
4.4.50.0130.01312.75
4.4.40.0070.03012.75
4.4.30.0070.04012.75
4.4.20.0170.02712.75
4.4.10.0070.02712.75
4.4.00.0070.02712.75
4.3.110.0070.01312.75
4.3.100.0130.03012.75
4.3.90.0030.02312.75
4.3.80.0070.05712.75
4.3.70.0130.01712.75
4.3.60.0100.03312.75
4.3.50.0100.03312.75
4.3.40.0100.05012.75
4.3.30.0030.03712.75
4.3.20.0030.03312.75
4.3.10.0100.01312.75
4.3.00.0030.03712.75

preferences:
259.07 ms | 1398 KiB | 8 Q