note
merlyn
<code>
#!/usr/bin/perl
undef $/;
while (<>) {
print "File $ARGV has ", length(), " total length\n";
while (/([^\n\r\x20-\x7f])/g) {
print "File $ARGV has character ", ord($1), " at byte ", pos()-1, "\n";
}
print "File $ARGV has ", tr/\n//, " total lines\n";
}
</code>
<p>-- <a href="http://www.stonehenge.com/merlyn/">Randal L. Schwartz, Perl hacker</a></p>
150070
150070