3v4l.org

run code in 300+ PHP versions simultaneously
<?php $words=['MVW','MWAH','MWAH','MYW','MW','MY9AH','MYQAH','MYQAH','MY9AH','MYQAH', 'MYQAH','MWAH','MYQAH','MYSWI','MYQAH','MYQAH','MW','MW','MW','MW']; $chars=array_map('str_split',$words); usort($chars,function($a,$b){return sizeof($b)-sizeof($a);}); $result=''; foreach($chars[0] as $col=>$not_used){ $occurrences=array_count_values(array_column($chars,$col)); // no NULL values arsort($occurrences); $result.=key($occurrences); } echo $result;

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.70.0040.01118.68
8.3.60.0130.00318.30
8.3.50.0110.00318.30
8.3.40.0130.00318.79
8.3.30.0070.00718.65
8.3.20.0070.00021.89
8.3.10.0050.00321.95
8.3.00.0040.00419.79
8.2.190.0040.01116.58
8.2.180.0130.01020.13
8.2.170.0060.00922.96
8.2.160.0100.00320.29
8.2.150.0080.00024.18
8.2.140.0150.00024.66
8.2.130.0070.00019.39
8.2.120.0040.00426.35
8.2.110.0160.00720.99
8.2.100.0060.00617.91
8.2.90.0050.00317.72
8.2.80.0040.00418.04
8.2.70.0040.00417.78
8.2.60.0100.00317.80
8.2.50.0000.00718.16
8.2.40.0000.00720.55
8.2.30.0000.00719.35
8.2.20.0030.00518.00
8.2.10.0110.00018.13
8.2.00.0040.00418.06
8.1.280.0100.00625.92
8.1.270.0040.00422.19
8.1.260.0040.00426.35
8.1.250.0040.00428.09
8.1.240.0060.00322.13
8.1.230.0120.00321.02
8.1.220.0000.00817.74
8.1.210.0030.00518.96
8.1.200.0060.00317.13
8.1.190.0000.00817.22
8.1.180.0000.00818.10
8.1.170.0040.00418.51
8.1.160.0000.00718.82
8.1.150.0050.00320.18
8.1.140.0000.00717.76
8.1.130.0040.00418.94
8.1.120.0050.00217.52
8.1.110.0000.00717.54
8.1.100.0030.00517.43
8.1.90.0030.00517.45
8.1.80.0000.00817.48
8.1.70.0050.00317.36
8.1.60.0060.00617.61
8.1.50.0000.00817.56
8.1.40.0000.00717.43
8.1.30.0030.00617.59
8.1.20.0040.00417.70
8.1.10.0000.00817.61
8.1.00.0000.00717.56
8.0.300.0000.00719.73
8.0.290.0080.00016.75
8.0.280.0000.00718.40
8.0.270.0050.00316.93
8.0.260.0030.00316.84
8.0.250.0070.00016.88
8.0.240.0080.00017.06
8.0.230.0030.00316.97
8.0.220.0000.00716.96
8.0.210.0030.00316.99
8.0.200.0000.00817.02
8.0.190.0030.00316.96
8.0.180.0030.00316.82
8.0.170.0040.00416.88
8.0.160.0070.00416.86
8.0.150.0030.00516.73
8.0.140.0040.00416.74
8.0.130.0000.00513.36
8.0.120.0040.00416.96
8.0.110.0040.00416.91
8.0.100.0000.00716.94
8.0.90.0070.00016.77
8.0.80.0180.00516.78
8.0.70.0050.00216.95
8.0.60.0030.00516.88
8.0.50.0000.00816.95
8.0.30.0110.00917.02
8.0.20.0100.01017.40
8.0.10.0020.00517.00
8.0.00.0120.00516.87
7.4.330.0000.00515.55
7.4.320.0060.00016.65
7.4.300.0030.00316.61
7.4.290.0070.00016.58
7.4.280.0040.00416.55
7.4.270.0040.00416.66
7.4.260.0030.00516.55
7.4.250.0040.00416.45
7.4.240.0000.00716.57
7.4.230.0000.00716.36
7.4.220.0000.00716.60
7.4.210.0120.00316.48
7.4.200.0040.00416.39
7.4.160.0110.00616.47
7.4.150.0100.00717.40
7.4.140.0070.01017.86
7.4.130.0070.01016.43
7.4.120.0110.00916.51
7.4.110.0110.00716.46
7.4.100.0060.01016.52
7.4.90.0130.00916.43
7.4.80.0160.00619.39
7.4.70.0070.01316.46
7.4.60.0070.00716.51
7.4.50.0070.01116.39
7.4.40.0060.00916.58
7.4.00.0080.00814.96
7.3.330.0050.00013.36
7.3.320.0000.00613.20
7.3.310.0000.00716.47
7.3.300.0000.00716.41
7.3.290.0000.00816.30
7.3.280.0090.00616.24
7.3.270.0130.00317.40
7.3.260.0110.01116.50
7.3.240.0070.01016.54
7.3.230.0090.01216.50
7.3.210.0110.00716.59
7.3.200.0040.01116.23
7.3.190.0100.00616.33
7.3.180.0070.01016.28
7.3.170.0120.00416.27
7.3.160.0120.00416.68
7.3.10.0090.00316.62
7.3.00.0100.00716.52
7.2.330.0150.00316.54
7.2.320.0090.00916.64
7.2.310.0060.01316.75
7.2.300.0080.01416.58
7.2.290.0080.00916.64
7.2.130.0110.00316.82
7.2.120.0000.01116.77
7.2.110.0030.00716.91
7.2.100.0090.00416.67
7.2.90.0060.01016.64
7.2.80.0070.00317.10
7.2.70.0030.00717.18
7.2.60.0110.00616.96
7.2.50.0030.00716.81
7.2.40.0040.00816.86
7.2.30.0060.00616.73
7.2.20.0060.01318.47
7.2.10.0060.01118.26
7.2.00.0050.01018.37
7.1.250.0000.00815.72
7.1.200.0030.01215.81
7.1.140.0090.01118.70
7.1.130.0050.00718.58
7.1.120.0100.00718.79
7.1.110.0030.00317.75
7.1.100.0030.00418.26
7.1.90.0080.01218.02
7.1.80.0090.01217.93
7.1.70.0070.01316.83
7.1.60.0300.02234.98
7.1.50.0320.01734.69
7.1.40.0320.01934.43
7.1.30.0270.01434.51
7.1.20.0270.01934.61
7.1.10.0100.01116.65
7.1.00.0060.01416.63

preferences:
17.59 ms | 401 KiB | 5 Q