foreach is the keyword used to start a foreach loop.
foreach my $variable (@list) …;
use 5.10.0; %favorite = (joe => 'red', sam => 'blue', walter => 'black'); %list = %favorite; say "%favorite = "; foreach my $element (%favorite) { say $element; }
%favorite = walter black joe red sam blue