3v4l.org

run code in 300+ PHP versions simultaneously
<?php $arrays = array ( 0 => array( "location" => "Breakwater", "bsid" => "105c" ), 1 => array( "location" => "Breakwater", "bsid" => "105c" ), 2 => array( "location" => "Breakwater", "bsid" => "105c" ), 3 => array( "location" => "Whateverelse", "bsid" => "105c" ) ); $count = array(); foreach($arrays as $simple) { $count []= $simple['location']; } var_dump($count['Breakwater']);

preferences:
47.26 ms | 402 KiB | 5 Q