我不确定如何使以下代码有效:
if(response!==("usernamewrong" OR "passwordwrong")){
print("login Wrong");
} else {
//if anything else other than the two shows up into the response goes here
}
答案 0 :(得分:2)
在条件中进行多项检查时,您必须明确:
if (response == "usernamewrong" || response == "passwordwrong")