3v4l.org

run code in 300+ PHP versions simultaneously
<?php $places = array((object)array('PlaceId' => 837, 'Name' => 'United Arab Emirates', 'Type' => 'Country'), (object)array('PlaceId' => 838, 'Name' => 'Afghanistan', 'Type' => 'Country'), (object)array('PlaceId' => 839, 'Name' => 'Antigua and Barbuda', 'Type' => 'Country') ); if (($k = array_search(837, array_column($places, 'PlaceId'))) !== false) { print_r($places[$k]); } else { echo "Not found!"; }

preferences:
36.86 ms | 406 KiB | 5 Q