# *always* use these - they do (some of) your error # checking for you! - saves *lots* of time use strict; use warnings; #this is right my $x = 4; my $y = 4; for (1..$x) { #this bit is wrong - see discussion below print "*" x $y, "\n"; }