标签:his 一个 height utf-8 计算 doc doctype mouseover type
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>js考试</title>
</head>
<script type="text/javascript">
// 1.编写一个程序,计算增加后的工资。要求基本工资大于等于1000元,增加20%的工资;若小于1000元且大于等于800元,则增加15%,若小于800元,则增加10%工资。
var pay = 1000;
if (pay >= 1000){
pay += (pay * 0.2);
}
else if (pay < 1000 && pay >= 800){
pay += (pay * 0.15);
}
else if (pay < 800){
pay += (pay * 0.1);
}
document.write("最后工资为"+pay+"</br>");
</script>
<body>
<div onmouseover="mOver(this)" onmouseout="mOut(this)" style="height: 50px; width: 200px; background-color: #ADD8E6; color: red" ></div>
</body>
</html>
标签:his 一个 height utf-8 计算 doc doctype mouseover type
原文地址:http://www.cnblogs.com/tangtangsimida/p/7407131.html