3v4l.org

run code in 300+ PHP versions simultaneously
<?php function isJson($string) { $decoded = json_decode($string); if ( !is_object($decoded) && !is_array($decoded) ) { return false; } return (json_last_error() == JSON_ERROR_NONE); } if ( isJson(123) ) { echo "valid JSON"; } else { echo "not valid JSON"; }

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.10.0090.00019.61
8.3.140.0040.01516.37
8.3.130.0030.01018.29
8.3.120.0000.01018.75
8.3.110.0030.00620.94
8.3.100.0030.00616.56
8.3.90.0130.00726.77
8.3.80.0090.00316.38
8.3.70.0150.00616.75
8.3.60.0150.00018.30
8.3.50.0110.00818.27
8.3.40.0090.01218.67
8.3.30.0130.00318.70
8.3.20.0000.00720.91
8.3.10.0000.00818.98
8.3.00.0000.00721.90
8.2.260.0080.00020.63
8.2.250.0000.01518.36
8.2.240.0070.00716.93
8.2.230.0080.00022.58
8.2.220.0040.01524.06
8.2.210.0090.00026.77
8.2.200.0060.00316.50
8.2.190.0040.01116.75
8.2.180.0100.01025.92
8.2.170.0150.00022.96
8.2.160.0110.00719.25
8.2.150.0060.00624.18
8.2.140.0030.00524.66
8.2.130.0040.00426.16
8.2.120.0030.00519.89
8.2.110.0090.00019.14
8.2.100.0040.00718.14
8.2.90.0040.00419.31
8.2.80.0060.00317.97
8.2.70.0030.00617.50
8.2.60.0080.00018.03
8.2.50.0090.00018.07
8.2.40.0000.00819.88
8.2.30.0080.00018.01
8.2.20.0080.00017.96
8.2.10.0040.00718.80
8.2.00.0040.00419.32
8.1.310.0040.00418.31
8.1.300.0070.00317.88
8.1.290.0030.00730.84
8.1.280.0110.00425.92
8.1.270.0080.00022.14
8.1.260.0080.00028.09
8.1.250.0000.00828.09
8.1.240.0060.00322.81
8.1.230.0110.00020.88
8.1.220.0000.00817.76
8.1.210.0000.00818.77
8.1.200.0060.00317.36
8.1.190.0080.00017.35
8.1.180.0050.00318.10
8.1.170.0040.00418.57
8.1.160.0030.00518.89
8.1.150.0040.00418.87
8.1.140.0000.00718.90
8.1.130.0030.00317.33
8.1.120.0030.00317.35
8.1.110.0030.00317.41
8.1.100.0000.00717.53
8.1.90.0070.00417.49
8.1.80.0040.00417.50
8.1.70.0000.00717.50
8.1.60.0090.00017.57
8.1.50.0080.00017.54
8.1.40.0030.00517.54
8.1.30.0060.00317.66
8.1.20.0040.00417.56
8.1.10.0070.00717.51
8.1.00.0040.00417.48
8.0.300.0040.00419.64
8.0.290.0040.00416.75
8.0.280.0050.00318.37
8.0.270.0030.00316.74
8.0.260.0000.00716.71
8.0.250.0000.00716.82
8.0.240.0030.00316.98
8.0.230.0040.00417.00
8.0.220.0040.00716.87
8.0.210.0000.00716.89
8.0.200.0040.00416.87
8.0.190.0040.00416.83
8.0.180.0030.00716.94
8.0.170.0000.00916.81
8.0.160.0000.00816.89
8.0.150.0070.00016.77
8.0.140.0040.00816.76
8.0.130.0030.00413.37
8.0.120.0040.00416.82
8.0.110.0040.00416.83
8.0.100.0040.00416.97
8.0.90.0080.00016.96
8.0.80.0120.00416.92
8.0.70.0000.00716.78
8.0.60.0070.00016.96
8.0.50.0070.00016.93
8.0.30.0150.00616.84
8.0.20.0080.01116.95
8.0.10.0000.00717.08
8.0.00.0120.00816.71
7.4.330.0050.00015.55
7.4.320.0070.00016.50
7.4.300.0060.00016.61
7.4.290.0030.00516.62
7.4.280.0080.00016.39
7.4.270.0030.00316.66
7.4.260.0070.00016.60
7.4.250.0030.00316.52
7.4.240.0050.00316.66
7.4.230.0040.00416.59
7.4.220.0050.00316.40
7.4.210.0070.00916.52
7.4.200.0000.00716.60
7.4.140.0150.00317.86
7.4.130.0170.00716.52
7.4.120.0110.01416.45
7.4.110.0170.00716.45
7.4.100.0060.01216.61
7.4.90.0030.01316.36
7.4.80.0130.01019.39
7.4.70.0160.00916.51
7.4.60.0060.01016.61
7.4.50.0030.00916.41
7.4.40.0000.02116.64
7.4.00.0050.01115.02
7.3.330.0000.00513.25
7.3.320.0000.00613.22
7.3.310.0000.00716.25
7.3.300.0000.00716.12
7.3.290.0060.00016.15
7.3.280.0020.01316.18
7.3.260.0100.00816.36
7.3.240.0080.01116.29
7.3.230.0070.01016.42
7.3.210.0050.01316.20
7.3.200.0160.00316.40
7.3.190.0140.00716.43
7.3.180.0130.00316.34
7.3.170.0070.01416.46
7.3.160.0060.01216.51
7.3.120.0070.01114.94
7.3.110.0070.01014.54
7.3.100.0060.00614.65
7.3.90.0110.00714.67
7.3.80.0090.00314.64
7.3.70.0030.01014.60
7.3.60.0060.00314.49
7.3.50.0060.00514.65
7.3.40.0080.00814.83
7.3.30.0030.01414.80
7.3.20.0100.01115.72
7.3.10.0130.00315.68
7.3.00.0160.00315.58
7.2.330.0090.01316.58
7.2.320.0130.00316.36
7.2.310.0070.01016.46
7.2.300.0100.00716.46
7.2.290.0100.01016.64
7.2.250.0070.00714.75
7.2.240.0150.00614.80
7.2.230.0070.00714.95
7.2.220.0080.00415.20
7.2.210.0110.00615.20
7.2.200.0030.01014.96
7.2.190.0030.00615.11
7.2.180.0090.00714.92
7.2.170.0050.00915.08
7.2.160.0140.01115.04
7.2.150.0070.01115.20
7.2.140.0080.01115.11
7.2.130.0130.01515.08
7.2.120.0980.00715.07
7.2.110.0090.00314.94
7.2.100.0210.00615.08
7.2.90.0090.00614.90
7.2.80.0100.00314.97
7.2.70.0080.00615.18
7.2.60.0090.00915.06
7.2.50.0210.00015.15
7.2.40.0100.00615.22
7.2.30.0170.00815.04
7.2.20.0090.00914.90
7.2.10.0050.00815.03
7.2.00.0070.00714.83
7.1.330.0030.01015.91
7.1.320.0030.01015.88
7.1.310.0070.00415.72
7.1.300.0040.01115.81
7.1.290.0080.00015.54
7.1.280.0090.00514.80
7.1.270.0060.00814.86
7.1.260.0080.01114.76
7.1.250.0170.00813.96

preferences:
31.39 ms | 403 KiB | 5 Q