3v4l.org

run code in 300+ PHP versions simultaneously
<?php function xor_encrypt($in) { $key = 'haha'; $text = $in; $outText = ''; // Iterate through each character for($i=0;$i<strlen($text);$i++) { $outText .= $text[$i] ^ $key[$i % strlen($key)]; } return $outText; } echo xor_encrypt('lol'); // $arr = array( "showpassword"=>"yes", "bgcolor"=>"#0000ff"); // echo base64_encode(xor_encrypt(json_encode($arr))); // echo json_decode(xor_encrypt(base64_decode($arrd)), true); ?>

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.0090.00618.56
8.3.50.0150.00016.29
8.3.40.0100.00618.88
8.3.30.0110.00418.63
8.3.20.0040.00420.19
8.3.10.0060.00323.67
8.3.00.0030.00519.69
8.2.180.0060.00918.41
8.2.170.0150.00322.96
8.2.160.0100.00719.23
8.2.150.0080.00024.18
8.2.140.0040.00424.66
8.2.130.0000.00721.00
8.2.120.0030.00626.35
8.2.110.0040.00721.18
8.2.100.0090.00517.85
8.2.90.0020.00519.25
8.2.80.0040.00418.04
8.2.70.0030.00617.63
8.2.60.0040.00418.15
8.2.50.0040.00419.78
8.2.40.0040.00420.42
8.2.30.0040.00419.36
8.2.20.0000.00718.11
8.2.10.0000.00917.98
8.2.00.0040.00418.03
8.1.280.0090.00625.92
8.1.270.0040.00422.14
8.1.260.0040.00426.35
8.1.250.0040.00428.09
8.1.240.0040.00423.85
8.1.230.0040.00718.91
8.1.220.0080.00017.88
8.1.210.0000.00818.77
8.1.200.0090.00017.35
8.1.190.0080.00016.98
8.1.180.0000.00718.10
8.1.170.0000.00818.87
8.1.160.0050.00219.00
8.1.150.0030.00520.66
8.1.140.0030.00619.48
8.1.130.0040.00418.82
8.1.120.0000.00817.31
8.1.110.0030.00617.33
8.1.100.0030.00517.37
8.1.90.0040.00417.36
8.1.80.0030.00317.38
8.1.70.0030.00317.22
8.1.60.0070.00417.52
8.1.50.0080.00017.42
8.1.40.0090.00317.45
8.1.30.0070.00017.66
8.1.20.0040.00417.49
8.1.10.0000.00817.56
8.1.00.0000.00717.57
8.0.300.0040.00420.20
8.0.290.0000.00716.75
8.0.280.0000.00718.35
8.0.270.0000.00717.17
8.0.260.0040.00416.80
8.0.250.0040.00416.91
8.0.240.0070.00016.88
8.0.230.0030.00316.84
8.0.220.0040.00416.79
8.0.210.0000.00716.88
8.0.200.0030.00316.96
8.0.190.0090.00017.00
8.0.180.0000.00716.95
8.0.170.0050.00316.91
8.0.160.0030.00616.97
8.0.150.0000.00816.76
8.0.140.0070.00016.73
8.0.130.0030.00313.31
8.0.120.0000.00816.87
8.0.110.0040.00416.73
8.0.100.0040.00416.69
8.0.90.0050.00316.88
8.0.80.0050.01416.80
8.0.70.0070.00016.77
8.0.60.0000.00716.89
8.0.50.0000.00716.78
8.0.30.0130.00417.12
8.0.20.0050.01517.40
8.0.10.0040.00416.95
8.0.00.0060.01216.85
7.4.330.0000.00715.55
7.4.320.0030.00316.44
7.4.300.0050.00216.57
7.4.290.0030.00316.42
7.4.280.0030.00516.39
7.4.270.0000.00716.50
7.4.260.0050.00316.41
7.4.250.0040.00416.36
7.4.240.0030.00516.46
7.4.230.0030.00316.49
7.4.220.0130.00616.60
7.4.210.0110.00416.63
7.4.200.0000.00716.44
7.4.160.0140.00416.53
7.4.150.0090.00917.40
7.4.140.0070.01117.86
7.4.130.0070.01016.63
7.4.120.0090.01016.46
7.4.110.0070.01016.39
7.4.100.0050.01416.64
7.4.90.0140.00316.51
7.4.80.0080.01619.39
7.4.70.0070.01316.63
7.4.60.0060.01016.48
7.4.50.0100.00716.29
7.4.40.0090.00916.54
7.4.30.0040.01216.71
7.4.00.0030.01014.97
7.3.330.0000.00613.37
7.3.320.0060.00013.32
7.3.310.0030.00316.14
7.3.300.0000.00716.37
7.3.290.0060.00916.37
7.3.280.0070.00816.35
7.3.270.0120.00617.40
7.3.260.0130.00416.66
7.3.250.0050.01216.48
7.3.240.0080.00816.48
7.3.230.0030.01416.59
7.3.210.0140.00316.66
7.3.200.0080.00816.43
7.3.190.0060.01216.62
7.3.180.0070.01316.38
7.3.170.0050.01116.41
7.3.160.0130.00416.66
7.2.330.0060.01516.50
7.2.320.0040.01816.88
7.2.310.0030.01416.80
7.2.300.0180.00316.34
7.2.290.0120.00816.78
7.2.60.0090.00616.85
7.2.00.0100.00719.54
7.1.200.0070.00715.50
7.1.100.0000.01118.20
7.1.70.0100.00717.22
7.1.60.0190.00735.18
7.1.50.0220.00634.88
7.1.40.0160.01934.29
7.1.30.0190.01634.66
7.1.20.0190.01634.46
7.1.10.0060.01216.77
7.1.00.0080.00616.67
7.0.200.0030.01316.73
7.0.190.0070.00716.48
7.0.180.0070.01016.06
7.0.170.0030.01416.22
7.0.160.0110.01016.30
7.0.150.0040.01416.39
7.0.140.0090.00316.56
7.0.130.0030.01416.34
7.0.120.0070.01016.54
7.0.110.0060.01216.56
7.0.100.0100.00716.26
7.0.90.0090.00716.43
7.0.80.0040.01016.40
7.0.70.0060.01216.27
7.0.60.0100.00616.25
7.0.50.0020.01516.44
7.0.40.0000.01416.58
7.0.30.0060.00616.46
7.0.20.0040.01316.38
7.0.10.0090.00916.49
7.0.00.0060.01016.45

preferences:
47.81 ms | 401 KiB | 5 Q