Finding nonprintable characters?
VanL
vlindberg at verio.net
Tue Feb 19 14:14:39 EST 2002
Hello,
I have a function
isBinary(filehandle)
that I'm not sure how to implement. I've decided to define binary as
containing characters above \x80. But what is the best way to do this?
1. iterate through xreadline, so the whole thing doesn't get loaded into
memory?
2. String searching? If so, for what string? Searching for anything
greater than \x7f?
3. Re searching? for what class?
Thanks in advance,
Van
More information about the Python-list
mailing list