`
阅读更多
var num=33;
var number=0;
do{
number=window.prompt("输入数字",number);
document.write(typeof(number));
if(number==""||number==num){
break;
}
if(number>num){
document.write(number+"太大");
continue;
}else if(number<num){
document.write(number+"太小")
continue;
}else{
document.write(isNaN(number));
}

}while(true);
if(number==0){
document.write(number+"不猜了;")
}else{
document.write(number+"才对了")
}
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics