Another JavaScript Coding Question

Re: Another JavaScript Coding Question

by Andrea Bicciolo -
Number of replies: 0

W, while "==" is comparison, "||" is boolean, so "rat" || "mouse" evaluates "rat", thus fails your document.write statement.

"rat" && "mouse" --> "mouse" (And)

"rat" != "mouse" --> true (not equal)