Generally speaking, most built-in Perl functions return a value which indicates success, with a non-true value indicating failure (zero, empty string, or undef). Many user-written Perl functions follow the same convention.
System commands in Unix, Windows, etc., will result in a numeric exit value indicating an error, with zero indicating no error.