johnnywang has asked for the wisdom of the Perl Monks concerning the following question:
I was expecting the result to be:use strict; while(my $a=<DATA>){ print $a; } __END__ 1 2 3 __DATA__ a b c
But I actually got:a b c
So __END__ is equivalent to __DATA__? eveything after __END__ or __DATA__ can be accessed via <DATA>?1 2 3 __DATA__ a b c
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: __END__ is equivalent to __DATA__ ?
by Zaxo (Archbishop) on Dec 07, 2004 at 23:22 UTC | |
|
Re: __END__ is equivalent to __DATA__ ?
by mifflin (Curate) on Dec 07, 2004 at 23:11 UTC | |
by merlyn (Sage) on Dec 08, 2004 at 13:55 UTC | |
|
Re: __END__ is equivalent to __DATA__ ?
by ccn (Vicar) on Dec 07, 2004 at 23:22 UTC | |
|
Re: __END__ is equivalent to __DATA__ ?
by johnnywang (Priest) on Dec 08, 2004 at 18:28 UTC |