while (<STDIN>) { } # will read from standard input one line at a time
foreach (<STDIN>) { } # will read everything from standard input before looping
while (<STDIN>) { } # will read from standard input one line at a time
foreach (<STDIN>) { } # will read everything from standard input before looping