Learn JavaScript WHILE LOOPS in 8 minutes! đ
VloĆŸit
- Äas pĆidĂĄn 29. 10. 2023
- // while loop = repeat some code WHILE some condition is true
let loggedIn = false;
let username;
let password;
while(!loggedIn){
username = window.prompt(`Enter your username`);
password = window.prompt(`Enter your password`);
if(username === "myUsername" && password === "myPassword"){
loggedIn = true;
console.log("You are logged in!");
}
else{
console.log("Invalid credentials! Please try again");
}
}
// while loop = repeat some code WHILE some condition is true
let loggedIn = false;
let username;
let password;
while(!loggedIn){
username = window.prompt(`Enter your username`);
password = window.prompt(`Enter your password`);
if(username === "myUsername" && password === "myPassword"){
loggedIn = true;
console.log("You are logged in!");
}
else{
console.log("Invalid credentials! Please try again");
}
}
âHELP!â
- Bro Code
bro thank you very much, your videos help a lot to quickly and easily understand various topics, Greetings from Russia. And I would like to know when there will be courses in C#
Nice!
hey, you didn't say, what's up everybody? This is your bro here.
â€
Hey bro please what is the difference between this tutorials and the previous one ??
Do django next
3:19
im still waiting postgres videos :(
Do django pls
Can you explain me what this code ""${username}"" means
Its a placeholder, you need to use `` instead of "" to use it
DJANGO course Pls
Do django next
Do django next