3v4l.org

run code in 300+ PHP versions simultaneously
<?php $userInfo = array('city' => 0); function isNull($userInfo,$id){ If($userInfo[$id] == 0){ $res = "Не указано"; } else{ if($id == 'city'){ $res = $userInfo[$id]->title; }else{ $res = $userInfo[$id]; } } return $res; } $city = isNull($userInfo,"city");

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)
8.3.60.0040.01116.75
8.3.50.0150.00016.15
8.3.40.0110.00318.70
8.3.30.0160.00018.57
8.3.20.0080.00020.21
8.3.10.0000.00721.69
8.3.00.0090.00019.13
8.2.180.0140.00718.23
8.2.170.0060.01022.96
8.2.160.0080.00520.55
8.2.150.0040.00424.18
8.2.140.0070.00024.66
8.2.130.0000.00821.00
8.2.120.0040.00426.35
8.2.110.0100.00720.39
8.2.100.0040.00717.72
8.2.90.0040.00419.28
8.2.80.0040.00417.97
8.2.70.0030.00617.63
8.2.60.0000.00817.93
8.2.50.0050.00318.10
8.2.40.0060.00320.41
8.2.30.0040.00420.94
8.2.20.0000.00718.11
8.2.10.0090.00018.10
8.2.00.0050.00218.04
8.1.280.0130.00725.92
8.1.270.0040.00422.05
8.1.260.0040.00426.35
8.1.250.0000.00728.09
8.1.240.0100.00023.89
8.1.230.0100.00017.83
8.1.220.0050.00317.76
8.1.210.0030.00618.77
8.1.200.0040.00417.22
8.1.190.0040.00417.22
8.1.180.0050.00218.10
8.1.170.0000.00818.46
8.1.160.0070.00018.95
8.1.150.0040.00418.85
8.1.140.0040.00419.44
8.1.130.0000.00818.80
8.1.120.0070.00017.43
8.1.110.0030.00517.42
8.1.100.0000.00717.41
8.1.90.0020.00517.50
8.1.80.0040.00417.34
8.1.70.0000.00817.47
8.1.60.0040.00417.55
8.1.50.0050.00217.51
8.1.40.0060.00317.49
8.1.30.0040.00417.65
8.1.20.0000.00817.59
8.1.10.0070.00317.55
8.1.00.0000.00717.37
8.0.300.0000.00818.77
8.0.290.0000.00716.75
8.0.280.0000.00718.37
8.0.270.0070.00017.11
8.0.260.0030.00316.73
8.0.250.0000.00716.89
8.0.240.0050.00316.83
8.0.230.0050.00316.84
8.0.220.0080.00016.82
8.0.210.0030.00316.81
8.0.200.0000.00916.92
8.0.190.0040.00416.92
8.0.180.0040.00416.87
8.0.170.0070.00016.85
8.0.160.0040.00416.86
8.0.150.0050.00316.83
8.0.140.0000.00716.75
8.0.130.0030.00313.34
8.0.120.0040.00416.67
8.0.110.0000.00716.89
8.0.100.0040.00416.68
8.0.90.0030.00516.88
8.0.80.0060.00916.87
8.0.70.0030.00616.82
8.0.60.0040.00416.71
8.0.50.0080.00016.77
8.0.30.0090.00917.01
8.0.20.0110.01017.40
8.0.10.0050.00216.87
8.0.00.0080.00816.83
7.4.330.0050.00015.55
7.4.320.0000.00716.51
7.4.300.0000.00716.56
7.4.290.0030.00616.59
7.4.280.0050.00216.52
7.4.270.0000.00716.52
7.4.260.0070.00016.55
7.4.250.0030.00316.45
7.4.240.0040.00416.60
7.4.230.0000.00716.49
7.4.220.0140.01016.57
7.4.210.0070.00716.66
7.4.200.0000.00716.62
7.4.160.0090.01016.33
7.4.150.0110.00717.40
7.4.140.0090.01117.86
7.4.130.0120.00616.37
7.4.120.0090.00916.53
7.4.110.0040.01416.54
7.4.100.0120.01216.30
7.4.90.0120.00816.56
7.4.80.0060.01019.39
7.4.70.0130.01016.32
7.4.60.0060.01016.44
7.4.50.0120.00316.41
7.4.40.0080.00816.39
7.4.30.0100.00616.48
7.4.00.0030.01014.66
7.3.330.0030.00313.24
7.3.320.0050.00013.24
7.3.310.0000.00716.14
7.3.300.0070.00016.10
7.3.290.0070.00716.20
7.3.280.0100.00916.24
7.3.270.0040.01517.40
7.3.260.0080.00916.27
7.3.250.0110.00716.43
7.3.240.0110.01016.40
7.3.230.0110.00716.42
7.3.210.0130.00316.52
7.3.200.0070.01416.49
7.3.190.0070.01016.49
7.3.180.0000.01816.33
7.3.170.0150.00616.41
7.3.160.0070.01016.31
7.3.120.0070.01014.76
7.3.110.0060.00914.96
7.3.100.0070.00714.66
7.3.90.0030.00914.55
7.3.80.0000.01314.79
7.3.70.0090.00614.85
7.3.60.0070.00314.61
7.3.50.0070.00714.88
7.3.40.0040.00814.76
7.3.30.0120.00314.75
7.3.20.0090.00316.76
7.3.10.0060.00916.48
7.3.00.0070.01016.70
7.2.330.0170.00016.34
7.2.320.0150.00316.52
7.2.310.0100.00716.38
7.2.300.0120.00916.25
7.2.290.0070.01016.47
7.2.240.0070.00714.73
7.2.230.0000.01514.91
7.2.220.0040.00714.82
7.2.210.0070.00714.77
7.2.200.0000.01114.96
7.2.190.0030.00614.87
7.2.180.0030.00914.86
7.2.170.0030.00714.84
7.2.160.0030.00914.98
7.2.150.0060.00616.86
7.2.140.0060.00916.75
7.2.130.0080.00416.96
7.2.120.0070.00716.84
7.2.110.0080.00416.89
7.2.100.0040.01116.77
7.2.90.0080.00816.70
7.2.80.0050.00516.71
7.2.70.0090.00616.94
7.2.60.0060.00816.78
7.2.50.0040.01116.59
7.2.40.0030.00816.84
7.2.30.0070.00717.05
7.2.20.0030.01116.95
7.2.10.0120.00316.90
7.2.00.0100.00518.19
7.1.330.0070.00715.64
7.1.320.0030.01015.80
7.1.310.0040.01115.91
7.1.300.0070.00715.85
7.1.290.0040.01115.80
7.1.280.0030.00915.80
7.1.270.0060.00315.45
7.1.260.0030.00715.81
7.1.250.0040.00415.87
7.1.200.0040.00815.84
7.1.100.0040.00818.19
7.1.70.0070.00717.04
7.1.60.0180.00935.09
7.1.50.0400.00934.79
7.1.40.0130.01634.39
7.1.30.0160.01334.42
7.1.20.0320.01032.67
7.1.10.0270.00314.75
7.1.00.0050.00816.73
7.0.200.0090.00614.86
7.0.190.0030.01016.81
7.0.180.0000.01516.10
7.0.170.0210.00614.41
7.0.160.1060.00714.41
7.0.150.0110.01416.09
7.0.140.0090.00316.28
7.0.130.0170.01014.91
7.0.120.0210.00614.79
7.0.110.0000.01416.40
7.0.100.0000.01416.37
7.0.90.0150.01114.34
7.0.80.0100.00316.32
7.0.70.0050.01016.02
7.0.60.0190.00614.31
7.0.50.0180.00614.46
7.0.40.0170.00716.54
7.0.30.0190.01614.64
7.0.20.0110.00316.30
7.0.10.0220.00314.64
7.0.00.0190.00614.73

preferences:
50.16 ms | 400 KiB | 5 Q