use warnings; use strict; for my $color (qw(red blue)) { for my $size (qw(sm med lrg)) { for my $num (1..4) { print "$color-$size-$num\n"; } } }