This JavaScript code should run indefinitely until an empty string is provided, but it doesn't. Why?

后端 未结 0 1063
臣服心动
臣服心动 2020-11-21 19:16
let yourName;
do {
  yourName = prompt("Who are you?");
} while (!yourName);
console.log(yourName);

This code is given in an online textbo

相关标签:
回答
  • 消灭零回复
提交回复
热议问题