3v4l.org

run code in 300+ PHP versions simultaneously
<?php function authorform_form_alter_custom_sort($a,$b){ $orderPL = array('A','Ą','B','C','Ć','D','E','Ę','F','G','H','I','J','K','L','Ł','M','N','Ń','O','Ó','P','Q','R','S','Ś','T','U','V','W','X','Y','Z','Ź','Ż', 'a','ą','b','c','ć','d','e','ę','f','g','h','i','j','k','l','ł','m','n','ń','o','ó','p','q','r','s','ś','t','u','v','w','x','y','z','ź','ż'); if ($a == $b) { return 0; } if (mb_substr($a, 0, 1, 'utf-8') == mb_substr($b, 0, 1, 'utf-8')) { return authorform_form_alter_custom_sort(substr($a, 1),substr($b, 1)); } return (array_search($a, $orderPL) < array_search($b, $orderPL)) ? -1 : 1; } echo authorform_form_alter_custom_sort("Olko","Pietraśko");

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.40.0130.00718.67
8.3.30.0150.00018.68
8.3.20.0040.00420.24
8.3.10.0050.00321.87
8.3.00.0090.00019.25
8.2.170.0000.01422.96
8.2.160.0040.01120.39
8.2.150.0050.00324.18
8.2.140.0080.00024.66
8.2.130.0070.00026.16
8.2.120.0040.00419.77
8.2.110.0060.00619.21
8.2.100.0030.00917.63
8.2.90.0000.00819.04
8.2.80.0030.00517.97
8.2.70.0060.00317.50
8.2.60.0000.00817.93
8.2.50.0030.00518.07
8.2.40.0060.00319.88
8.2.30.0040.00417.94
8.2.20.0000.00717.63
8.2.10.0000.00817.99
8.2.00.0040.00417.75
8.1.270.0090.00023.73
8.1.260.0000.00826.35
8.1.250.0040.00428.09
8.1.240.0030.00622.04
8.1.230.0030.00717.48
8.1.220.0040.00417.74
8.1.210.0030.00618.77
8.1.200.0000.00817.35
8.1.190.0000.00817.23
8.1.180.0000.00818.10
8.1.170.0040.00420.29
8.1.160.0040.00421.96
8.1.150.0000.00818.80
8.1.140.0000.00717.38
8.1.130.0070.00017.71
8.1.120.0000.00717.36
8.1.110.0000.00817.48
8.1.100.0040.00417.48
8.1.90.0000.00717.45
8.1.80.0000.00717.45
8.1.70.0000.00717.39
8.1.60.0020.00517.47
8.1.50.0050.00317.41
8.1.40.0050.00317.62
8.1.30.0000.00917.71
8.1.20.0080.00017.74
8.1.10.0090.00017.53
8.1.00.0070.00017.53
8.0.300.0040.00418.77
8.0.290.0000.00716.88
8.0.280.0000.00718.50
8.0.270.0030.00317.29
8.0.260.0060.00017.27
8.0.250.0000.00616.89
8.0.240.0000.00717.02
8.0.230.0040.00417.00
8.0.220.0070.00017.00
8.0.210.0040.00416.95
8.0.200.0030.00316.98
8.0.190.0000.00816.95
8.0.180.0040.00416.95
8.0.170.0000.00817.04
8.0.160.0000.00717.01
8.0.150.0030.00316.99
8.0.140.0040.00416.96
8.0.130.0000.00813.38
8.0.120.0040.00416.94
8.0.110.0040.00417.01
8.0.100.0000.00717.00
8.0.90.0040.00416.75
8.0.80.0030.01816.96
8.0.70.0000.00716.94
8.0.60.0040.00416.95
8.0.50.0040.00417.00
8.0.30.0200.00617.16
8.0.20.0100.01117.40
8.0.10.0040.00416.92
8.0.00.0110.00716.66
7.4.330.0000.00515.18
7.4.320.0030.00316.43
7.4.300.0060.00316.61
7.4.290.0000.00716.59
7.4.280.0080.00016.61
7.4.270.0040.00416.61
7.4.260.0050.00216.61
7.4.250.0030.00316.47
7.4.240.0020.00516.59
7.4.230.0030.00316.71
7.4.220.0070.01116.68
7.4.210.0110.00316.55
7.4.200.0030.00316.71
7.4.160.0170.00016.61
7.4.150.0030.02017.40
7.4.140.0110.00917.86
7.4.130.0110.01116.60
7.4.120.0080.00816.57
7.4.110.0060.01216.68
7.4.100.0130.00316.32
7.4.90.0120.00616.39
7.4.80.0100.00719.39
7.4.70.0150.00816.66
7.4.60.0060.01016.55
7.4.50.0080.00016.58
7.4.40.0060.01016.48
7.4.30.0110.01116.52
7.4.10.0140.00415.06
7.4.00.0080.01014.88
7.3.330.0020.00213.25
7.3.320.0130.00013.23
7.3.310.0050.00316.27
7.3.300.0040.00416.25
7.3.290.0100.00716.30
7.3.280.0100.00816.31
7.3.270.0080.01117.40
7.3.260.0120.01216.24
7.3.250.0080.00816.39
7.3.240.0110.00816.62
7.3.230.0100.00716.48
7.3.210.0110.01116.52
7.3.200.0000.01619.39
7.3.190.0060.00916.67
7.3.180.0060.01416.59
7.3.170.0100.00716.46
7.3.160.0040.01516.27
7.3.130.0070.01114.88
7.3.120.0090.00315.13
7.3.110.0060.01014.80
7.3.100.0040.00714.81
7.3.90.0070.00714.70
7.3.80.0060.00614.95
7.3.70.0040.01114.89
7.3.60.0040.00814.75
7.3.50.0030.01314.86
7.3.40.0040.01114.96
7.3.30.0040.01115.01
7.3.20.0090.00616.65
7.3.10.0070.00316.54
7.3.00.0080.00816.67
7.2.330.0140.00716.43
7.2.320.0160.00816.49
7.2.310.0030.01616.71
7.2.300.0040.01416.39
7.2.290.0070.01016.61
7.2.260.0090.00915.18
7.2.250.0120.00615.23
7.2.240.0130.00315.00
7.2.230.0030.01315.07
7.2.220.0150.00014.94
7.2.210.0040.00714.98
7.2.200.0060.00914.98
7.2.190.0030.00615.07
7.2.180.0100.00714.90
7.2.170.0060.00315.17
7.2.160.0030.00915.03
7.2.150.0030.00617.07
7.2.140.0000.00916.84
7.2.130.0030.00916.68
7.2.120.0080.00516.66
7.2.110.0050.00816.95
7.2.100.0070.00716.79
7.2.90.0050.00517.02
7.2.80.0040.00516.94
7.2.70.0030.00716.99
7.2.60.0000.01316.64
7.2.50.0120.00016.81
7.2.40.0000.00916.91
7.2.30.0080.00416.93
7.2.20.0100.00317.05
7.2.10.0100.00716.99
7.2.00.0050.00918.15
7.1.330.0000.01415.85
7.1.320.0060.00615.59
7.1.310.0000.01015.93
7.1.300.0070.00715.76
7.1.290.0090.00315.53
7.1.280.0100.00315.71
7.1.270.0030.00615.75
7.1.260.0100.00315.97
7.1.250.0030.00915.86
7.1.240.0030.00715.69
7.1.230.0000.01215.75
7.1.220.0080.00315.63
7.1.210.0070.00715.76
7.1.200.0070.00715.61
7.1.190.0080.00015.89
7.1.180.0040.00915.70
7.1.170.0100.00316.01
7.1.160.0030.00715.47
7.1.150.0030.01015.76
7.1.140.0030.01015.74
7.1.130.0070.01015.58
7.1.120.0090.00015.70
7.1.110.0000.01215.83
7.1.100.0050.00917.10
7.1.90.0070.00415.87
7.1.80.0030.01415.85
7.1.70.0000.01316.32
7.1.60.0050.01217.71
7.1.50.0060.00316.52
7.1.40.0120.00015.97
7.1.30.0040.01115.82
7.1.20.0070.01015.79
7.1.10.0040.01115.62
7.1.00.0070.04019.01
7.0.330.0030.00915.50
7.0.320.0030.00915.50
7.0.310.0000.01015.27
7.0.300.0040.00415.27
7.0.290.0040.00415.41
7.0.280.0000.01315.33
7.0.270.0060.00715.50
7.0.260.0050.00515.24
7.0.250.0030.00615.64
7.0.240.0070.00715.62
7.0.230.0000.01115.17
7.0.220.0110.00615.34
7.0.210.0100.00015.63
7.0.200.0040.00616.06
7.0.190.0040.00815.51
7.0.180.0110.00015.66
7.0.170.0000.01615.52
7.0.160.0070.00315.34
7.0.150.0000.01315.27
7.0.140.0060.04118.77
7.0.130.0000.00815.64
7.0.120.0040.00815.30
7.0.110.0120.00015.45
7.0.100.0070.00715.47
7.0.90.0060.00615.26
7.0.80.0110.00315.51
7.0.70.0050.00515.10
7.0.60.0050.05017.69
7.0.50.0050.03916.65
7.0.40.0090.04316.98
7.0.30.0150.03116.79
7.0.20.0150.03716.76
7.0.10.0100.02516.95
7.0.00.0160.03716.87
5.6.400.0000.01214.66
5.6.390.0090.00914.40
5.6.380.0000.01314.50
5.6.370.0030.00614.53
5.6.360.0070.00714.32
5.6.350.0080.00314.55
5.6.340.0030.01114.55
5.6.330.0100.00714.49
5.6.320.0060.00613.80
5.6.310.0030.01214.27
5.6.300.0060.00914.24
5.6.290.0060.00614.41
5.6.280.0050.04017.75
5.6.270.0120.00614.56
5.6.260.0070.00714.30
5.6.250.0100.00314.11
5.6.240.0070.00714.45
5.6.230.0060.00614.30
5.6.220.0040.01214.44
5.6.210.0080.04317.54
5.6.200.0070.04016.13
5.6.190.0070.04517.34
5.6.180.0150.04417.36
5.6.170.0150.02517.51
5.6.160.0080.02117.45
5.6.150.0100.03516.26
5.6.140.0060.02916.29
5.6.130.0120.03416.20
5.6.120.0040.04617.82
5.6.110.0070.04317.66
5.6.100.0080.04017.65
5.6.90.0020.02617.66
5.6.80.0040.02217.39
5.6.70.0130.04317.33
5.6.60.0060.00914.06
5.6.50.0070.01013.92
5.6.40.0030.01314.36
5.6.30.0100.00314.41
5.6.20.0030.01314.30
5.6.10.0030.01214.23
5.6.00.0030.01014.61
5.5.380.0040.00714.37
5.5.370.0030.01014.15
5.5.360.0000.01814.43
5.5.350.0050.04617.41
5.5.340.0030.03416.22
5.5.330.0070.03617.49
5.5.320.0020.02717.32
5.5.310.0080.02717.40
5.5.300.0030.02316.10
5.5.290.0090.03616.13
5.5.280.0060.03617.47
5.5.270.0080.04217.45
5.5.260.0050.04617.68
5.5.250.0070.03717.43
5.5.240.0120.03317.33
5.5.230.0070.00714.20
5.5.220.0000.01414.45
5.5.210.0100.00314.43
5.5.200.0030.00914.33
5.5.190.0030.01014.36
5.5.180.0040.00714.25
5.5.170.0090.00614.44
5.5.160.0000.01214.20
5.5.150.0080.00314.26
5.5.140.0140.00014.34
5.5.130.0110.00314.27
5.5.120.0040.01114.11
5.5.110.0070.00714.41
5.5.100.0070.00314.00
5.5.90.0070.00414.37
5.5.80.0090.00914.06
5.5.70.0100.00714.14
5.5.60.0070.01014.45
5.5.50.0030.01014.13
5.5.40.0030.01014.14
5.5.30.0090.00914.13
5.5.20.0050.00514.11
5.5.10.0040.00414.39
5.5.00.0000.01314.21
5.4.450.0360.03615.23
5.4.440.0180.02915.21
5.4.430.0110.02615.24
5.4.420.0070.03215.48
5.4.410.0080.03215.22
5.4.400.0150.03014.98
5.4.390.0190.03214.78
5.4.380.0160.03614.93
5.4.370.0150.03714.80
5.4.360.0100.04014.93
5.4.350.0180.03514.86
5.4.340.0130.04214.77
5.4.330.0070.00410.98
5.4.320.0100.04214.74
5.4.310.0120.03914.86
5.4.300.0120.02914.88
5.4.290.0020.04115.02
5.4.280.0110.03114.79
5.4.270.0120.03814.76
5.4.260.0150.03814.83
5.4.250.0100.03314.83
5.4.240.0100.04114.91
5.4.230.0120.03014.84
5.4.220.0120.03714.80
5.4.210.0150.02814.81
5.4.200.0070.03613.86
5.4.190.0130.03314.94
5.4.180.0100.03014.78
5.4.170.0130.03414.73
5.4.160.0150.03814.79
5.4.150.0130.03714.87
5.4.140.0120.03613.66
5.4.130.0080.03213.63
5.4.120.0100.03113.65
5.4.110.0150.03013.64
5.4.100.0150.03213.73
5.4.90.0080.02813.64
5.4.80.0090.03013.74
5.4.70.0100.03013.63
5.4.60.0130.03913.74
5.4.50.0120.03813.59
5.4.40.0170.03413.59
5.4.30.0080.03113.65
5.4.20.0130.02613.77
5.4.10.0120.03013.53
5.4.00.0130.02313.46
5.3.290.0100.07714.81
5.3.280.0170.05014.78
5.3.270.0200.05014.68
5.3.260.0170.05314.61
5.3.250.0070.07014.68
5.3.240.0230.04714.83
5.3.230.0430.05014.66
5.3.220.0230.06314.76
5.3.210.0270.04714.63
5.3.200.0230.04714.59
5.3.190.0300.05014.63
5.3.180.0300.06014.80
5.3.170.0130.06714.57
5.3.160.0170.05014.64
5.3.150.0270.06314.69
5.3.140.0200.07314.59
5.3.130.0200.07714.59
5.3.120.0230.07314.68
5.3.110.0130.07314.68
5.3.100.0330.05714.11
5.3.90.0200.06714.21
5.3.80.0130.06014.14
5.3.70.0130.06014.14
5.3.60.0230.04714.04
5.3.50.0130.05314.16
5.3.40.0100.06014.04
5.3.30.0170.07013.99
5.3.20.0130.05013.75
5.3.10.0300.04713.65
5.3.00.0130.06013.69
5.2.170.0100.05011.22
5.2.160.0170.05011.16
5.2.150.0200.04011.26
5.2.140.0200.04311.16
5.2.130.0200.04311.12
5.2.120.0100.04711.15
5.2.110.0230.03711.22
5.2.100.0170.04011.15
5.2.90.0130.04311.25
5.2.80.0100.04311.13
5.2.70.0100.05711.16
5.2.60.0030.05311.14
5.2.50.0170.05311.07
5.2.40.0170.05011.11
5.2.30.0070.05011.02
5.2.20.0070.04711.19
5.2.10.0100.04711.10
5.2.00.0130.05010.72
5.1.60.0230.03010.04
5.1.50.0000.05010.05
5.1.40.0030.05310.00
5.1.30.0130.05010.55
5.1.20.0130.05010.51
5.1.10.0070.05310.21
5.1.00.0200.02710.30
5.0.50.0030.0378.57
5.0.40.0070.0338.42
5.0.30.0100.0438.29
5.0.20.0130.0278.33
5.0.10.0070.0408.24
5.0.00.0130.0508.19
4.4.90.0070.0305.92
4.4.80.0070.0305.99
4.4.70.0070.0235.90
4.4.60.0100.0235.89
4.4.50.0100.0275.91
4.4.40.0000.0435.93
4.4.30.0130.0205.96
4.4.20.0030.0276.10
4.4.10.0070.0236.08
4.4.00.0070.0405.96
4.3.110.0030.0335.95
4.3.100.0070.0235.83
4.3.90.0070.0205.83
4.3.80.0030.0375.86
4.3.70.0070.0305.83
4.3.60.0130.0175.82
4.3.50.0070.0235.86
4.3.40.0130.0275.87
4.3.30.0100.0204.62
4.3.20.0030.0304.58
4.3.10.0000.0274.55
4.3.00.0070.0236.93

preferences:
46.79 ms | 400 KiB | 5 Q