3v4l.org

run code in 300+ PHP versions simultaneously
<?php /* * Fill in all five below and click blue 'eval();' button below textarea. * * ------------------ */ $server_seed_hash = ''; #SHA-256 Server SEED $server_seed = ''; #Server SEED $client_seed = ''; #Client SEED $nonce = ''; #NONCE /* ------------------ */ if ($server_seed_hash == '' || $server_seed == '' || $client_seed == '' || $nonce == '') exit("Fill in details"); $server_seed_sha256 = hash('sha256', $server_seed); $hash = hash('sha256', $server_seed.'|'.$client_seed.'|'.$nonce); $num = hexdec(substr($hash, 0, 8)) % 10000 + 1; echo "Hash matches: ".($server_seed_hash == $server_seed_sha256 ? 'Yes': 'No')."\n"; echo "Generated number: $num";

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.0040.00419.08
8.4.10.0030.00619.58
8.3.140.0040.01518.20
8.3.130.0080.00018.48
8.3.120.0030.00620.54
8.3.110.0060.00320.94
8.3.100.0030.00524.06
8.3.90.0040.01126.77
8.3.80.0070.00316.63
8.3.70.0090.00616.58
8.3.60.0150.00318.52
8.3.50.0070.00716.46
8.3.40.0110.00718.48
8.3.30.0070.01118.71
8.3.20.0030.00624.18
8.3.10.0070.00024.66
8.3.00.0000.00826.16
8.2.260.0080.00016.53
8.2.250.0040.00416.58
8.2.240.0090.00016.93
8.2.230.0030.00622.58
8.2.220.0090.00037.54
8.2.210.0090.00626.77
8.2.200.0000.00916.75
8.2.190.0090.00916.63
8.2.180.0070.01025.92
8.2.170.0090.01222.96
8.2.160.0100.01022.96
8.2.150.0050.00325.66
8.2.140.0050.00324.66
8.2.130.0040.00426.16
8.2.120.0040.00719.54
8.2.110.0030.00622.13
8.2.100.0060.00618.03
8.2.90.0040.00419.29
8.2.80.0100.00019.09
8.2.70.0000.00817.63
8.2.60.0000.00818.05
8.2.50.0030.00518.07
8.2.40.0000.00918.35
8.2.30.0000.00818.00
8.2.20.0000.00817.93
8.2.10.0070.00019.29
8.2.00.0000.00719.22
8.1.310.0070.01118.57
8.1.300.0110.00418.23
8.1.290.0000.01018.88
8.1.280.0070.00725.92
8.1.270.0070.00323.91
8.1.260.0060.00326.35
8.1.250.0070.00028.09
8.1.240.0030.00620.90
8.1.230.0080.00418.87
8.1.220.0000.00817.79
8.1.210.0030.00619.04
8.1.200.0030.00717.23
8.1.190.0000.00817.23
8.1.180.0030.00718.10
8.1.170.0060.00318.90
8.1.160.0000.00718.86
8.1.150.0000.00718.84
8.1.140.0000.00718.98
8.1.130.0050.00219.23
8.1.120.0040.00717.46
8.1.110.0040.00417.51
8.1.100.0070.00017.37
8.1.90.0000.00717.46
8.1.80.0030.00617.44
8.1.70.0030.00317.45
8.1.60.0030.00617.57
8.1.50.0030.00617.43
8.1.40.0000.00917.41
8.1.30.0090.00017.61
8.1.20.0080.00817.53
8.1.10.0110.00517.42
8.1.00.0120.00417.34
8.0.300.0040.00419.83
8.0.290.0000.00716.63
8.0.280.0030.00318.32
8.0.270.0040.00418.06
8.0.260.0040.00416.79
8.0.250.0040.00416.86
8.0.240.0000.00817.06
8.0.230.0070.00016.98
8.0.220.0000.00716.95
8.0.210.0070.00017.04
8.0.200.0060.00016.90
8.0.190.0050.00217.01
8.0.180.0000.00816.88
8.0.170.0090.00016.82
8.0.160.0040.00416.99
8.0.150.0070.00616.85
8.0.140.0100.00516.78
8.0.130.0080.00415.08
8.0.120.0100.00416.81
8.0.110.0090.00516.86
8.0.100.0050.00516.85
8.0.90.0060.00616.93
8.0.80.0090.00616.93
8.0.70.0110.00216.85
8.0.60.0100.00316.93
8.0.50.0100.00516.77
8.0.30.0150.00716.86
8.0.20.0150.00616.97
8.0.10.0110.00916.98
8.0.00.0120.00616.97
7.4.330.0020.00215.55
7.4.320.0060.00016.41
7.4.300.0000.00616.59
7.4.290.0000.00716.50
7.4.280.0070.00016.60
7.4.270.0100.00616.55
7.4.260.0100.00414.93
7.4.250.0130.00216.49
7.4.240.0130.00216.40
7.4.230.0120.00516.39
7.4.220.0070.00516.47
7.4.210.0100.00416.58
7.4.200.0090.00416.59
7.4.190.0100.00416.59
7.4.180.0130.00416.46
7.4.160.0170.00616.53
7.4.150.0130.00816.61
7.4.140.0160.00416.41
7.4.130.0130.00816.53
7.4.120.0140.00516.50
7.4.110.0150.00316.44
7.4.100.0130.00716.53
7.4.90.0150.00316.43
7.4.80.0150.00516.46
7.4.70.0120.00816.50
7.4.60.0190.00116.42
7.4.50.0150.00516.36
7.4.40.0130.00516.29
7.4.30.0160.00316.52
7.4.20.0120.00916.44
7.4.10.0120.00716.42
7.4.00.0140.00516.47
7.3.330.0070.00516.27
7.3.320.0080.00414.62
7.3.310.0110.00216.10
7.3.300.0090.00416.23
7.3.290.0080.00616.22
7.3.280.0160.00516.22
7.3.270.0130.00516.25
7.3.260.0120.00716.25
7.3.250.0150.00516.22
7.3.240.0100.01016.23
7.3.230.0170.00516.19
7.3.220.0130.00716.15
7.3.210.0160.00616.20
7.3.200.0120.00616.18
7.3.190.0150.00616.17
7.3.180.0150.00616.12
7.3.170.0140.00516.16
7.3.160.0130.00716.13
7.3.150.0150.00616.13
7.3.140.0170.00816.13
7.3.130.0160.00216.14
7.3.120.0170.00416.14
7.3.110.0160.00416.04
7.3.100.0110.00816.07
7.3.90.0080.01116.47
7.3.80.0160.00216.11
7.3.70.0090.00816.27
7.3.60.0140.00416.29
7.3.50.0150.00416.28
7.3.40.0140.00416.34
7.3.30.0150.00316.25
7.3.20.0130.00717.55
7.3.10.0150.00517.38
7.3.00.0170.00417.49

preferences:
67.65 ms | 403 KiB | 5 Q