var box3 = (parseInt(prompt("请输入一个月份"))) if (box3 == 1 || box3 == 3 || box3 == 5 || box3 == 7 || box3 == 8 || box3 == 10 || box3 == 12) { alert('这个月有31天') } else if (box3 == 4 || box3 == 6 || box3 == 9 || box3 == 11) { alert('这个月有30天') } else if (box3 == 2) { alert('这个月有28天') } else { alert('请输入正确的月份') }