最近中文字幕高清中文字幕无,亚洲欧美高清一区二区三区,一本色道无码道dvd在线观看 ,一个人看的www免费高清中文字幕

為了賬號安全,請及時綁定郵箱和手機立即綁定
已解決430363個問題,去搜搜看,總會有你想問的

急,在線等。彈不出結(jié)果。

急,在線等。彈不出結(jié)果。

同7七 2015-04-20 18:31:40
<!DOCTYPE HTML><html>?? ?<head>?? ??? ??? ?<meta charset="utf-8"/>?? ??? ?<title>6編程練習</title>?? ??? ?</head>?? ??? ?<body>?? ??? ??? ?<script type="text/javascript">?? ??? ??? ??? ??? ?function tong(){?? ??? ??? ??? ?var a = parseInt(document.getElementById)("txt1").value);?? ??? ??? ??? ?var b = document.getElementById)("select").value;?? ??? ??? ??? ?var c = parseInt(document.getElementById)("txt2").value);?? ??? ??? ??? ?var result;?? ??? ??? ??? ?switch(b){?? ??? ??? ??? ?case "+":?? ??? ??? ??? ??? ?result = a + c;?? ??? ??? ??? ??? ?break;?? ??? ??? ??? ?case "-":?? ??? ??? ??? ??? ?result = a - c;?? ??? ??? ??? ??? ?break;?? ??? ??? ??? ?case "*":?? ??? ??? ??? ??? ?result = a * c;?? ??? ??? ??? ??? ?break;?? ??? ??? ??? ?default:?? ??? ??? ??? ??? ?result = a / c;?? ??? ??? ??? ?}?? ??? ??? ??? ?document.getElementById("adc").value = result;?? ??? ??? ?}?? ??? ??? ??? ??? ??? ??? ?</script>?? ??? ?<input type="text" id="txt1"/>?? ??? ?<select id="select">?? ??? ??? ??? ??? ?<option value="+">+</option>?? ??? ??? ?<option value="-">-</option>?? ??? ??? ?<option value="*">*</option>?? ??? ??? ?<option value="/">/</option>?? ??? ??? ??? ?</select>?? ??? ?<input type="text" id="txt2"/>?? ??? ?<input type="button" value="=" onclick="tong()"/>?? ??? ?<input type="text" id="adc"/>?? ??? ?</body></html>
查看完整描述

2 回答

?
尐兀

TA貢獻1條經(jīng)驗 獲得超0個贊

?var a = parseInt(document.getElementById("txt1").value);

查看完整回答
反對 回復 2015-04-21
  • 2 回答
  • 0 關注
  • 1252 瀏覽
慕課專欄
更多

添加回答

舉報

0/150
提交
取消
微信客服

購課補貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動學習伙伴

公眾號

掃描二維碼
關注慕課網(wǎng)微信公眾號