http://www.perlmonks.org?node_id=113695

Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

#!/usr/bin/perl -w use strict; my $foo_text .= $_ while (<DATA>); print "$foo_text\n"; __DATA__ foo wears foo shoes at the foo store.
produces the following error:
Use of uninitialized value at foo.pl line 4, <DATA> chunk 1 (#1)
Any one know what's going on here? Please, to aid in my learning/understanding of Perl a reason why this does not work and not a solution would be very much appreciated.

-Steven Woodard