3v4l.org

run code in 300+ PHP versions simultaneously
<?php $var1= ""; $var2= ""; $var3= "3"; $temp_array = array($var1,$var2,$var3); $temp_count =count(array_filter($temp_array)); if($temp_count ==1){ echo "1 variable is not empty"; } else { echo "total variable is = ".$temp_count; }

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.4.20.0130.00717.75
8.4.10.0030.00619.66
8.3.150.0110.00716.98
8.3.140.0040.00416.64
8.3.130.0000.01118.38
8.3.120.0070.00318.80
8.3.110.0030.00720.94
8.3.100.0000.01024.06
8.3.90.0080.00026.77
8.3.80.0060.00316.50
8.3.70.0070.00716.58
8.3.60.0180.00416.63
8.3.50.0140.00522.05
8.3.40.0110.00318.76
8.3.30.0070.00718.70
8.3.20.0040.00420.21
8.3.10.0060.00323.66
8.3.00.0040.00422.43
8.2.260.0090.00918.84
8.2.250.0080.00018.41
8.2.240.0040.00419.04
8.2.230.0000.00822.58
8.2.220.0030.00637.54
8.2.210.0090.00026.77
8.2.200.0030.00716.50
8.2.190.0100.01016.63
8.2.180.0140.00716.50
8.2.170.0100.01018.94
8.2.160.0000.01422.13
8.2.150.0030.00524.18
8.2.140.0050.00224.66
8.2.130.0040.00422.08
8.2.120.0040.00426.35
8.2.110.0000.00921.06
8.2.100.0040.00717.72
8.2.90.0040.00419.38
8.2.80.0090.00017.97
8.2.70.0030.00517.75
8.2.60.0040.00417.63
8.2.50.0080.00018.04
8.2.40.0080.00017.80
8.2.30.0060.00319.12
8.2.20.0020.00517.64
8.2.10.0040.00418.12
8.2.00.0040.00417.73
8.1.310.0200.00018.64
8.1.300.0130.00316.31
8.1.290.0060.00318.88
8.1.280.0060.00925.92
8.1.270.0030.00523.99
8.1.260.0040.00428.09
8.1.250.0070.00028.09
8.1.240.0070.00423.79
8.1.230.0090.00320.89
8.1.220.0000.00817.78
8.1.210.0000.00818.89
8.1.200.0030.00617.36
8.1.190.0000.00917.35
8.1.180.0000.00818.10
8.1.170.0060.00317.62
8.1.160.0040.00422.10
8.1.150.0060.00318.79
8.1.140.0030.00519.59
8.1.130.0000.00717.74
8.1.120.0070.00017.36
8.1.110.0000.00717.46
8.1.100.0040.00417.49
8.1.90.0030.00517.47
8.1.80.0000.00717.52
8.1.70.0040.00717.46
8.1.60.0000.00817.46
8.1.50.0000.00817.55
8.1.40.0030.00617.47
8.1.30.0040.00417.55
8.1.20.0070.00017.71
8.1.10.0000.00817.49
8.1.00.0070.00017.43
8.0.300.0070.00019.98
8.0.290.0050.00316.75
8.0.280.0030.00318.36
8.0.270.0030.00317.19
8.0.260.0000.00717.38
8.0.250.0030.00316.95
8.0.240.0060.00316.89
8.0.230.0050.00316.81
8.0.220.0000.00716.88
8.0.210.0000.00716.78
8.0.200.0060.00016.82
8.0.190.0000.00716.88
8.0.180.0000.00816.90
8.0.170.0040.00416.80
8.0.160.0070.00016.80
8.0.150.0000.00716.85
8.0.140.0030.00516.88
8.0.130.0030.00513.21
8.0.120.0050.00316.88
8.0.110.0000.00716.84
8.0.100.0040.00416.70
8.0.90.0030.00316.96
8.0.80.0060.00916.95
8.0.70.0040.00416.69
8.0.60.0070.00016.71
8.0.50.0050.00216.84
8.0.30.0100.00917.16
8.0.20.0120.00817.40
8.0.10.0070.00017.04
8.0.00.0140.00816.84
7.4.330.0050.00015.08
7.4.320.0030.00316.59
7.4.300.0000.00616.62
7.4.290.0040.00416.43
7.4.280.0040.00416.49
7.4.270.0000.00616.52
7.4.260.0070.00016.59
7.4.250.0000.00816.45
7.4.240.0030.00516.52
7.4.230.0070.00016.64
7.4.220.0050.01416.63
7.4.210.0000.01416.53
7.4.200.0000.00716.48
7.4.160.0140.00216.44
7.4.150.0110.00617.40
7.4.140.0110.00917.86
7.4.130.0080.01016.62
7.4.120.0110.00616.51
7.4.110.0070.01516.41
7.4.100.0120.00916.61
7.4.90.0120.00616.57
7.4.80.0130.00319.39
7.4.70.0180.00416.38
7.4.60.0030.01516.42
7.4.50.0030.01016.51
7.4.40.0060.01016.64
7.4.30.0130.00616.36
7.4.00.0100.00315.00
7.3.330.0060.00013.00
7.3.320.0050.00013.17
7.3.310.0070.00016.24
7.3.300.0000.00716.31
7.3.290.0080.01016.29
7.3.280.0100.00816.27
7.3.270.0040.01217.40
7.3.260.0100.00816.45
7.3.250.0070.00916.35
7.3.240.0000.01616.44
7.3.230.0030.01316.44
7.3.210.0120.00316.28
7.3.200.0120.00416.41
7.3.190.0030.01316.26
7.3.180.0090.00616.31
7.3.170.0110.00516.57
7.3.160.0180.00316.37
7.2.330.0030.01516.43
7.2.320.0090.01216.78
7.2.310.0070.01116.62
7.2.300.0040.01516.54
7.2.290.0120.00616.60
7.2.60.0110.00716.77
7.2.00.0000.01219.54
7.1.200.0070.00715.90
7.1.70.0030.00917.31
7.1.60.0000.01116.93
7.1.00.0030.07022.43
7.0.200.0090.00614.88
7.0.100.0470.05319.96
7.0.90.0370.06320.01
7.0.80.0470.05320.06
7.0.70.0270.06720.00
7.0.60.0430.05319.94
7.0.50.0430.06720.40
7.0.40.0470.05020.32
7.0.30.0370.07720.41
7.0.20.0330.06320.42
7.0.10.0300.06320.43
7.0.00.0300.06720.39
5.6.250.0070.06320.63
5.6.240.0170.05720.58
5.6.230.0070.07320.64
5.6.220.0100.06020.71
5.6.210.0070.06020.69
5.6.200.0100.06021.09
5.6.190.0100.05721.20
5.6.180.0270.07021.07
5.6.170.0030.06721.06
5.6.160.0130.05321.11
5.6.150.0100.05721.11
5.6.140.0170.05721.06
5.6.130.0130.06021.08
5.6.120.0030.07021.07
5.6.110.0170.05721.17
5.6.100.0070.06321.05
5.6.90.0130.06021.05
5.6.80.0130.05320.52
5.6.70.0200.04720.48
5.6.60.0130.05020.57
5.6.50.0170.05020.47
5.6.40.0230.06020.56
5.6.30.0130.05320.46
5.6.20.0170.05020.38
5.6.10.0100.06020.50
5.6.00.0230.04720.44

preferences:
69.32 ms | 403 KiB | 5 Q