3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arr = array( 'id' => '4c44c3e074ffc928250576cc', 'name' => 'Salvation Army', 'contact' => array( 'phone' => '2122899617', 'formattedPhone' => '(212) 289-9617' ), 'location' => array ( 'address' => '26 E 125th St', 'crossStreet' => 'btw Madison & 5th Ave', 'lat' => '40.805853703834', 'lng' => '-73.941053819056', 'distance' => '53', 'postalCode' => '10035', 'cc' => 'US', 'city' => 'New York', 'state' => 'NY', 'country' => 'United States' ), 'categories' => Array ( [ 'id' => '4bf58dd8d48988d101951735', 'name' => 'Thrift / Vintage Store', 'pluralName' => 'Thrift / Vintage Stores', 'shortName' => 'Thrift / Vintage', 'icon' => array ( 'prefix' => 'https://ss1.4sqi.net/img/categories_v2/shops/default_', 'suffix' => '.png' ), 'primary' => '1', ] ), 'verified' => '', 'restricted' => '1', 'stats' => array ( 'checkinsCount' => '71', 'usersCount' => '46', 'tipCount' => '3' ), 'specials' => array ( 'count' => '0', 'items' => Array() ), 'hereNow' => array ( 'count' => '0', 'groups' => Array() ), 'referralId' => 'v-1393405742' ); class Venue { protected $id; protected $categories; protected $contact; protected $fourSquareVenueId; protected $location; protected $name; protected $statistics; public function __construct() { $this->categories = new ArrayCollection(); } /** * Get id * * @return id $id */ public function getId() { return $this->id; } /** * Add category * * @param \Trist\Bundle\CommonBundle\Document\Venue\VenueCategory $category */ public function addCategory(VenueCategory $category) { $this->categories[] = $category; } /** * Remove category * * @param \Trist\Bundle\CommonBundle\Document\Venue\VenueCategory $category */ public function removeCategory(VenueCategory $category) { $this->categories->removeElement($category); } /** * Get categories * * @return \Doctrine\Common\Collections\ArrayCollection $categories */ public function getCategories() { return $this->categories; } /** * Set contact * * @param \Trist\Bundle\CommonBundle\Document\Venue\VenueContact $contact * @return self */ public function setContact(VenueContact $contact) { $this->contact = $contact; return $this; } } $obj = json_decode(json_encode($arr)); /* $obj= new stdClass(); foreach ($arr as $k=> $v) { $obj->{$k} = $v; } */ print_r((new ReflectionObject(new Venue))->getMethods());

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.00718.43
8.3.50.0150.00321.15
8.3.40.0120.00618.79
8.3.30.0100.00719.04
8.3.20.0000.00920.03
8.3.10.0070.00022.10
8.3.00.0040.00422.40
8.2.180.0070.00716.50
8.2.170.0100.01022.96
8.2.160.0070.00720.39
8.2.150.0000.00824.18
8.2.140.0000.00824.66
8.2.130.0140.00326.16
8.2.120.0000.00819.41
8.2.110.0090.00022.32
8.2.100.0040.00817.84
8.2.90.0080.00017.75
8.2.80.0000.00818.78
8.2.70.0040.00417.38
8.2.60.0000.00817.63
8.2.50.0000.00817.55
8.2.40.0030.00918.09
8.2.30.0040.00417.89
8.2.20.0040.00417.71
8.2.10.0030.00617.77
8.2.00.0050.00317.87
8.1.280.0100.00725.92
8.1.270.0160.00020.09
8.1.260.0060.00326.35
8.1.250.0020.00528.09
8.1.240.0040.00422.42
8.1.230.0070.00417.82
8.1.220.0000.00817.74
8.1.210.0060.00318.77
8.1.200.0060.00317.35
8.1.190.0090.00017.36
8.1.180.0080.00018.10
8.1.170.0000.00818.61
8.1.160.0040.00422.17
8.1.150.0090.00318.47
8.1.140.0000.00717.41
8.1.130.0030.00317.39
8.1.120.0040.00417.33
8.1.110.0080.00017.40
8.1.100.0000.00717.43
8.1.90.0040.00417.45
8.1.80.0070.00017.48
8.1.70.0030.00517.42
8.1.60.0040.00417.63
8.1.50.0000.00817.51
8.1.40.0040.00417.54
8.1.30.0040.00417.71
8.1.20.0030.00617.62
8.1.10.0060.00317.55
8.1.00.0000.00817.50
8.0.300.0040.00421.59
8.0.290.0060.00316.75
8.0.280.0000.00718.32
8.0.270.0000.00717.23
8.0.260.0000.00716.89
8.0.250.0000.00717.00
8.0.240.0000.00816.96
8.0.230.0000.00717.04
8.0.220.0020.00516.90
8.0.210.0000.00716.83
8.0.200.0040.00416.95
8.0.190.0030.00617.00
8.0.180.0080.00016.91
8.0.170.0000.00816.96
8.0.160.0000.00716.89
8.0.150.0080.00016.93
8.0.140.0030.00616.91
8.0.130.0030.00313.43
8.0.120.0000.00816.79
8.0.110.0040.00416.88
8.0.100.0000.00816.79
8.0.90.0050.00316.87
8.0.80.0070.01116.86
8.0.70.0040.00416.98
8.0.60.0040.00416.81
8.0.50.0040.00416.75
8.0.30.0130.00616.93
8.0.20.0090.01117.40
8.0.10.0000.00717.15
8.0.00.0110.01216.73
7.4.330.0000.00615.00
7.4.320.0030.00316.56
7.4.300.0000.00616.52
7.4.290.0000.00716.64
7.4.280.0030.00316.60
7.4.270.0070.00016.52
7.4.260.0030.00516.66
7.4.250.0000.00816.39
7.4.240.0050.00216.47
7.4.230.0030.00316.37
7.4.220.0140.00416.55
7.4.210.0080.00816.56
7.4.200.0040.00416.60
7.4.190.0040.00416.60
7.4.160.0110.01116.67
7.4.150.0150.00917.40
7.4.140.0110.00917.86
7.4.130.0090.00916.70
7.4.120.0060.01016.54
7.4.110.0060.01416.41
7.4.100.0180.00016.64
7.4.90.0110.01116.40
7.4.80.0140.00619.39
7.4.70.0060.01016.51
7.4.60.0110.00716.43
7.4.50.0000.00416.51
7.4.40.0070.00722.77
7.4.30.0030.01216.68
7.4.00.0100.00715.02
7.3.330.0050.00013.34
7.3.320.0030.00313.25
7.3.310.0070.00016.36
7.3.300.0000.00716.41
7.3.290.0100.01016.38
7.3.280.0070.00916.33
7.3.270.0060.00917.40
7.3.260.0100.00616.38
7.3.250.0100.00716.29
7.3.240.0160.00616.37
7.3.230.0150.00916.54
7.3.210.0060.01316.55
7.3.200.0040.01219.39
7.3.190.0030.01316.56
7.3.180.0090.00916.34
7.3.170.0100.01016.49
7.3.160.0100.00616.57
7.3.120.0030.01014.67
7.2.330.0090.01316.68
7.2.320.0120.00916.35
7.2.310.0100.01316.57
7.2.300.0160.00016.73
7.2.290.0060.01216.31
7.2.60.0090.00016.78
7.2.00.0150.00518.96
7.1.200.0150.00615.54
7.1.100.0000.01018.39
7.1.70.0070.00317.04
7.1.60.0130.01319.82
7.1.50.0110.00417.00
7.1.00.0030.03322.45
7.0.200.0000.00716.72
7.0.140.0030.06322.12
7.0.90.0100.07719.98
7.0.80.0200.07719.93
7.0.70.0100.05019.82
7.0.60.0100.07320.08
7.0.50.0530.06720.36
7.0.40.0030.09020.18
7.0.30.0100.04320.14
7.0.20.0070.08320.08
7.0.10.0100.08320.12
7.0.00.0100.08020.02
5.6.280.0070.07020.95
5.6.240.0070.08320.51
5.6.230.0070.08020.77
5.6.220.0200.06720.63
5.6.210.0100.08020.63
5.6.200.0070.08721.13
5.6.190.0100.08321.02
5.6.180.0100.08321.15
5.6.170.0070.08020.96
5.6.160.0030.08721.05
5.6.150.0000.08321.13
5.6.140.0200.07021.13
5.6.130.0100.08021.04
5.6.120.0130.05721.05
5.6.110.0130.07721.05
5.6.100.0100.07021.06
5.6.90.0070.08721.10
5.6.80.0070.06320.42
5.6.70.0170.07020.38
5.6.60.0030.08320.45
5.6.50.0100.06320.57
5.6.40.0100.06720.40
5.6.30.0000.05720.49
5.6.20.0130.07720.41
5.6.10.0100.08720.43
5.6.00.0100.04720.42
5.5.380.0030.04720.52
5.5.370.0100.06020.44
5.5.360.0100.08020.33
5.5.350.0000.08020.41
5.5.340.0130.07720.82
5.5.330.0200.04320.91
5.5.320.0100.07720.80
5.5.310.0030.05320.82
5.5.300.0130.05020.89
5.5.290.0000.06320.91
5.5.280.0100.05020.82
5.5.270.0170.07020.93
5.5.260.0100.07720.84
5.5.250.0130.05720.66
5.5.240.0170.05320.24
5.5.230.0100.07020.20
5.5.220.0070.06720.19
5.5.210.0070.08020.16
5.5.200.0070.04720.27
5.5.190.0100.04320.14
5.5.180.0100.07320.27
5.5.160.0100.07020.10
5.5.150.0030.09020.01
5.5.140.0170.05320.27
5.5.130.0000.05020.25
5.5.120.0130.06320.18
5.5.110.0100.07020.19
5.5.100.0170.06720.09
5.5.90.0030.07720.08
5.5.80.0230.06720.18
5.5.70.0130.07320.11
5.5.60.0070.07320.16
5.5.50.0130.06019.98
5.5.40.0100.07320.04
5.5.30.0100.07720.11
5.5.20.0030.08320.07
5.5.10.0070.08020.08
5.5.00.0170.07320.04
5.4.450.0070.08019.46
5.4.440.0000.07719.36
5.4.430.0130.07019.27
5.4.420.0100.08019.35
5.4.410.0070.08319.40
5.4.400.0070.05019.05
5.4.390.0100.07719.13
5.4.380.0100.06319.05
5.4.370.0070.04719.18
5.4.360.0170.06719.03
5.4.350.0100.06019.09
5.4.340.0030.04718.96
5.4.320.0100.05019.18
5.4.310.0030.07319.23
5.4.300.0100.07319.06
5.4.290.0070.04719.12
5.4.280.0100.07318.87
5.4.270.0030.05319.02
5.4.260.0070.08319.23
5.4.250.0070.07719.20
5.4.240.0070.08018.87
5.4.230.0130.07019.04
5.4.220.0070.08019.12
5.4.210.0100.07318.90
5.4.200.0030.07719.02
5.4.190.0130.06719.04
5.4.180.0070.06019.04
5.4.170.0070.07718.84
5.4.160.0070.04018.93
5.4.150.0070.07319.14
5.4.140.0070.07316.41
5.4.130.0100.06316.38
5.4.120.0100.06016.34
5.4.110.0030.06316.30
5.4.100.0030.05716.52
5.4.90.0070.07016.36
5.4.80.0070.05016.44
5.4.70.0130.06016.54
5.4.60.0000.06316.36
5.4.50.0070.04316.46
5.4.40.0030.07016.52
5.4.30.0100.06716.26
5.4.20.0130.05716.46
5.4.10.0130.06716.50
5.4.00.0070.07315.80
5.3.290.0130.06714.49
5.3.280.0070.06014.59
5.3.270.0070.06314.59
5.3.260.0070.05014.59
5.3.250.0030.07014.54
5.3.240.0070.07314.54
5.3.230.0070.05014.45
5.3.220.0100.06314.50
5.3.210.0070.05014.51
5.3.200.0000.04314.54
5.3.190.0070.07014.53
5.3.180.0070.07314.55
5.3.170.0070.06314.48
5.3.160.0100.06714.55
5.3.150.0100.06314.42
5.3.140.0030.07314.52
5.3.130.0130.03714.50
5.3.120.0030.08314.55
5.3.110.0130.06714.39
5.3.100.0070.07313.95
5.3.90.0030.07013.98
5.3.80.0070.07314.03
5.3.70.0130.07313.98
5.3.60.0030.06014.00
5.3.50.0100.06713.73
5.3.40.0130.07313.93
5.3.30.0070.07713.82
5.3.20.0070.08313.45
5.3.10.0130.05713.64
5.3.00.0030.07013.64
5.2.170.0070.05310.98
5.2.160.0030.03711.13
5.2.150.0100.03311.09
5.2.140.0100.07011.13
5.2.130.0100.06011.14
5.2.120.0100.05010.96
5.2.110.0070.05710.96
5.2.100.0030.04011.09
5.2.90.0070.03311.14
5.2.80.0030.06311.05
5.2.70.0070.05311.15
5.2.60.0030.04711.05
5.2.50.0000.05710.99
5.2.40.0000.06010.84
5.2.30.0070.05710.97
5.2.20.0030.04010.96
5.2.10.0030.06010.88
5.2.00.0130.04310.79
5.1.60.0030.06010.05
5.1.50.0030.03710.00
5.1.40.0030.02710.00
5.1.30.0030.04710.39
5.1.20.0130.04310.28
5.1.10.0030.03010.05
5.1.00.0000.03010.15
5.0.50.0070.0208.59
5.0.40.0030.0478.45
5.0.30.0030.0408.25
5.0.20.0100.0338.09
5.0.10.0000.0278.19
5.0.00.0070.0638.24
4.4.90.0000.0377.73
4.4.80.0070.0377.73
4.4.70.0000.0337.73
4.4.60.0030.0177.73
4.4.50.0000.0277.73
4.4.40.0000.0507.73
4.4.30.0070.0277.73
4.4.20.0000.0337.73
4.4.10.0030.0337.73
4.4.00.0000.0377.73
4.3.110.0030.0237.73
4.3.100.0000.0307.73
4.3.90.0070.0177.73
4.3.80.0000.0437.73
4.3.70.0000.0237.73
4.3.60.0000.0377.73
4.3.50.0000.0407.73
4.3.40.0030.0507.73
4.3.30.0000.0377.73
4.3.20.0030.0307.73
4.3.10.0000.0177.73
4.3.00.0000.0237.73

preferences:
49.22 ms | 401 KiB | 5 Q