[ad_1]
If it helps you to understand, you can rewrite it from AND to OR:
while (command != "quit" && command != "q") {
// do job
}
is equivalent to
while (!(command === "quit" || command === "q")) {
// do job
}
5
[ad_2]
solved OR and AND operator confusion in Javascript [closed]