So, you want to test string equality in Perl? You just use ‘==’ right? Wrong. In Perl, that will only test number equality which could cause a few problems and inconsistencies.
The Wrong Way:
$mystring = “”;
# wrong way
if ( $mystring == “” )
print $mystring; #will never print