in reply to String comparison "\x00" vs. "".
warn ord(''); warn ord("\x00"); [download]
It might be more sensible for ord to return undef when given the empty string. But if you are using ord on a string that does not contain exactly one character, that probably means you've already missed a step in the logic flow. :)