Suppose a variable is set:
var variable1 = prompt ('Write "2", please'); It is necessary that, if the user enters a different value than "2", an error message appears. This can be done with if .
The question is how to make sure that after the error message, each time (cyclically) the prompt again with the same question, and so that the value entered in it is given to the variable1 ?