in reply to Re: To read Char-by-Char from a file
in thread To read Char-by-Char from a file

Absolutely. This has the added benefit to bypass Perl's buffered IO, which is what one really wants if (s)he needs to read a precise amount of data from a "source".

In addition, if you want to read byte-by-byte instead of char-by-char (which is different due to Unicode support), it's safer to use binmode:

binmode FILE; sysread(FILE,$buffer,1);

Flavio (perl -e 'print(scalar(reverse("\nti.xittelop\@oivalf")))')

Don't fool yourself.