for ($i = 0; $i < $#mylist ; $i++) { say "first element" if ( $i == 0 ); }