I have made 2 variables named username and password and I want to test if they are both true but the prompt does not seem to pop up. I do not understand, I also am pretty new to code and really want to learn how to do this
var 1 = false;
var 2 - false;
function login() {
var username = prompt("Username");
var password = prompt("Password");
if (username == "wouterXD") {
1 = true;
} else {
1 = false;
}
if (password == "Wout2003!") {
2 = true;
} else {
2 = false;
}
};
if (1 = false && 2 = false) {
alert("Wrong Password and Username!");
login();
}