3v4l.org

run code in 300+ PHP versions simultaneously
<?php $array = [ 0 => [ 'attrb1' => 'test', 'attrb2' => 'test', ], 1 => [ 'attrb1' => 'test', 'attrb2' => 'test', ], ]; array_map(function($elem) { var_dump($element); }, $array);
Output for 8.0.0alpha1 - alpha2
Warning: Undefined variable $element in /in/NjvRR on line 15 NULL Warning: Undefined variable $element in /in/NjvRR on line 15 NULL
Output for 7.2.0 - 7.2.31, 7.3.0 - 7.3.19, 7.4.0 - 7.4.7
Notice: Undefined variable: element in /in/NjvRR on line 15 NULL Notice: Undefined variable: element in /in/NjvRR on line 15 NULL