+ 1

Hello, How can I alert after 3 wrong answers?

Greetings, I wanna know that how can I alert user that he is lost the game after 3 wrong guesses. Remember no other lost be alerted without 3 wrong guesses.

13th Oct 2022, 2:54 PM
Adarsh Addee
Adarsh Addee - avatar
3 Answers
+ 2
https://code.sololearn.com/W9wOF9wfBoX0/?ref=app This is a demo Hope this Helps!
13th Oct 2022, 3:59 PM
Random
Random - avatar
+ 3
You have a few languages there, but the pop-up alert is for JavaScript. You could create a variable for collecting wrong answers and when it reaches 3, call the alert.
13th Oct 2022, 2:56 PM
Ausgrindtube
Ausgrindtube - avatar
14th Oct 2022, 2:39 AM
Adarsh Addee
Adarsh Addee - avatar