3v4l.org

run code in 300+ PHP versions simultaneously
<?php $string = 'abed'; function convert_to_int($string) {; $characters = array_merge([' '], range('a', 'z')); return str_replace(array_values($characters), array_keys($characters), $string); } echo convert_to_int('abed'); echo "\n"; echo convert_to_int('abed 5');

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.0140.00018.04
8.3.50.0080.00618.21
8.3.40.0130.01018.45
8.3.30.0150.00018.72
8.3.20.0050.00220.73
8.3.10.0040.00421.74
8.3.00.0080.00022.40
8.2.180.0090.00916.50
8.2.170.0090.00622.96
8.2.160.0090.00621.19
8.2.150.0000.00824.18
8.2.140.0040.00424.66
8.2.130.0040.00419.72
8.2.120.0000.00826.35
8.2.110.0100.00022.19
8.2.100.0040.00819.35
8.2.90.0040.00417.75
8.2.80.0040.00418.78
8.2.70.0080.00017.50
8.2.60.0040.00417.75
8.2.50.0000.00817.55
8.2.40.0060.00319.34
8.2.30.0000.00719.19
8.2.20.0050.00318.06
8.2.10.0000.00719.19
8.2.00.0070.00018.26
8.1.280.0140.00025.92
8.1.270.0050.00320.31
8.1.260.0000.00826.35
8.1.250.0040.00428.09
8.1.240.0090.00020.89
8.1.230.0070.00420.97
8.1.220.0080.00018.72
8.1.210.0080.00018.77
8.1.200.0000.00917.09
8.1.190.0040.00417.10
8.1.180.0040.00418.10
8.1.170.0040.00418.53
8.1.160.0040.00418.82
8.1.150.0030.00618.73
8.1.140.0090.00019.01
8.1.130.0070.00017.38
8.1.120.0030.00317.40
8.1.110.0000.00717.30
8.1.100.0090.00017.40
8.1.90.0080.00017.43
8.1.80.0030.00317.25
8.1.70.0030.00517.39
8.1.60.0030.00517.55
8.1.50.0030.00517.51
8.1.40.0090.00017.42
8.1.30.0040.00417.59
8.1.20.0040.00417.54
8.1.10.0030.00617.39
8.1.00.0040.00417.49
8.0.300.0090.00018.77
8.0.290.0040.00416.58
8.0.280.0070.00018.48
8.0.270.0070.00017.27
8.0.260.0000.00716.71
8.0.250.0060.00316.80
8.0.240.0030.00316.91
8.0.230.0000.00816.84
8.0.220.0070.00016.84
8.0.210.0070.00016.79
8.0.200.0030.00316.78
8.0.190.0050.00316.87
8.0.180.0050.00316.76
8.0.170.0030.00516.87
8.0.160.0080.00016.68
8.0.150.0040.00416.80
8.0.140.0070.00016.73
8.0.130.0000.00513.34
8.0.120.0000.00716.77
8.0.110.0000.00716.73
8.0.100.0040.00416.82
8.0.90.0000.00716.66
8.0.80.0060.00916.79
8.0.70.0000.00716.70
8.0.60.0000.00716.65
8.0.50.0000.00716.77
8.0.30.0050.01216.97
8.0.20.0120.00617.04
8.0.10.0050.00216.95
8.0.00.0120.00816.84
7.4.330.0050.00016.78
7.4.320.0000.00616.46
7.4.300.0070.00016.47
7.4.290.0030.00616.49
7.4.280.0040.00416.54
7.4.270.0040.00416.58
7.4.260.0040.00416.38
7.4.250.0070.00016.44
7.4.240.0000.00716.45
7.4.230.0000.00716.71
7.4.220.0060.00316.70
7.4.210.0080.00616.57
7.4.200.0030.00316.48
7.4.160.0100.00816.56
7.4.140.0200.00617.86
7.4.130.0080.01016.59
7.4.120.0080.01216.72
7.4.110.0120.00316.49
7.4.100.0090.01316.50
7.4.90.0150.00416.43
7.4.80.0100.00719.39
7.4.70.0070.01116.57
7.4.60.0080.00816.69
7.4.50.0070.00716.27
7.4.40.0100.00616.45
7.4.00.0000.01314.77
7.3.330.0000.00513.19
7.3.320.0060.00013.00
7.3.310.0000.00716.25
7.3.300.0030.00316.23
7.3.290.0070.01016.18
7.3.280.0120.00616.23
7.3.260.0120.00616.41
7.3.240.0080.00916.45
7.3.230.0130.00416.52
7.3.210.0120.00916.49
7.3.200.0160.00016.23
7.3.190.0060.01116.66
7.3.180.0070.01016.29
7.3.170.0060.01216.55
7.3.160.0100.00616.10
7.3.30.0100.01014.60
7.3.20.1140.00314.82
7.3.10.0880.00314.88
7.3.00.1110.00014.72
7.2.330.0130.00916.43
7.2.320.0170.00316.71
7.2.310.0070.01016.75
7.2.300.0090.01616.70
7.2.290.0070.01316.74
7.2.160.0110.00714.91
7.2.150.0990.00015.09
7.2.140.1240.00315.08
7.2.130.1090.00014.99
7.2.120.1010.00715.03
7.2.110.0830.00315.18
7.2.100.1060.00314.87
7.2.90.0860.00614.86
7.2.80.0900.00715.11
7.2.70.1120.01014.75
7.2.60.1080.01014.86
7.2.50.1100.01414.78
7.2.40.0840.00714.84
7.2.30.1070.00015.15
7.2.20.1720.01015.24
7.2.10.0930.00715.02
7.2.00.0760.01015.15
7.1.270.0920.01013.64
7.1.260.1030.01014.08
7.1.250.1180.00713.86

preferences:
64.53 ms | 400 KiB | 5 Q