In the same line as my last question.... once I tried to understand how Perl was interpreting string comparisons, I started experimenting with different strings.

What is Perl doing here? Why doesn't it use the "if" statement as a condition? It reassigns the variable value instead of using it as a conditional statement in the following code:

$password=bill;
if ($password = 'howard') {
        print "'$password' is a valid password.\n";
}else {
        print "'$password' is not valid.\n";
}

*******
This results in a printout that says: 'howard' is a valid password.

Thank you again,

Deborah


-- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to