SPUG: Tie::File module
Yitzchak Scott-Thoennes
sthoenna at efn.org
Thu Feb 19 12:45:47 CST 2004
On Thu, Feb 19, 2004 at 10:34:14AM -0800, Luis Medrano <lmzaldivar at mac.com> wrote:
> List,
>
> I try to experiment with Tie::file module buth I have a question. I'm running this code:
>
> tie @lines, 'Tie::File', 'file' or die ...;
>
> print "$line[0] \n";
> untie @lines;
>
> I was specting to print just one line of the file but it print the whole file. Any idea why or how can I do it so it will print just one line??
Have you messed with $/? Tie::File uses it to determine line endings.
More information about the spug-list
mailing list