On Sat, 19 May 2001 16:15:36 EDT, [EMAIL PROTECTED] wrote:

>Hello all. My goal is to take the first 50 characters of a 400 character 
>document and write it to a new file.

I think read() will do.

Otherwise, stuff the whole file into a string (undef $/ before reading a
"line"), and use substr() to get the first 50 characters.

        undef $/;
        $_ = <>;
        print substr($_, 0, 50);

-- 
        Bart.

Reply via email to