当前位置:网站首页>js成绩奖惩例题
js成绩奖惩例题
2022-06-27 07:20:00 【I am the sun?】
题目如下:
成绩在[90,100],奖励笔记本电脑
成绩在[75,89],奖励游戏一天
成绩在[60,74],奖励试题一套
成绩在[0,59],奖励辅导班补习
输错,这显示错误
代码如下:
<!--成绩在[90,100],奖励笔记本电脑
成绩在[75,89],奖励游戏一天
成绩在[60,74],奖励试题一套
成绩在[0,59],奖励辅导班补习
输错,这显示错误-->
<!DOCTYPE html>
<html lang="zh">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta http-equiv="X-UA-Compatible" content="ie=edge" />
<title>成绩决定奖惩</title>
<script type="text/javascript">
var grade = prompt("请输入你的成绩:");
if(grade > 100 || grade < 0 || isNaN(grade)){
alert("哪有成绩是 "+ grade +"的,走开");
}else if(grade >= 90){
alert("成绩 " + grade +"分,奖励一台笔记本电脑");
}else if(grade >= 75){
alert("成绩 " + grade +"分,奖励游戏一天");
}else if(grade >= 60){
alert("成绩 " + grade +"分,奖励试题一套");
}else{
alert("成绩才"+ grade +"分,奖励辅导班补习");
}
</script>
</head>
<body>
</body>
</html>
运行结果如下:









边栏推荐
- Window right click management
- R language analyzing wine data
- (已解决) npm突然报错 Cannot find module ‘D:\Program Files\nodejs\node_modules\npm\bin\npm-cli.js‘
- Installation and functions of uview
- R 语言 基于关联规则与聚类分析的消费行为统计
- (resolved) NPM suddenly reports an error cannot find module 'd:\program files\nodejs\node_ modules\npm\bin\npm-cli. js‘
- RNA SEQ data analysis in R - investigate differentially expressed genes in the data!
- OpenCV怎么下载?OpenCV下载后怎么配置?
- Interviewer: you use Lombok every day. What is its principle? I can't answer
- JDBC参数化查询示例
猜你喜欢
![Speech signal processing - concept (II): amplitude spectrum (STFT spectrum), Mel spectrum [the deep learning of speech mainly uses amplitude spectrum and Mel spectrum] [extracted with librosa or torch](/img/b3/6c8d9fc66e2a4dbdc0dd40179266d3.png)
Speech signal processing - concept (II): amplitude spectrum (STFT spectrum), Mel spectrum [the deep learning of speech mainly uses amplitude spectrum and Mel spectrum] [extracted with librosa or torch

Goodbye, agile Scrum
![[graduation season] graduation is the new beginning of your life journey. Are you ready](/img/4e/aa763455da974d9576a31568fc6625.jpg)
[graduation season] graduation is the new beginning of your life journey. Are you ready

Interviewer: you use Lombok every day. What is its principle? I can't answer

js打印99乘法表

Cookie加密6

Memory barrier store buffer, invalid queue

C# 请问怎么在更新数据库时候调用line与rows

Xiaomi Interviewer: let's talk about the proficient Registration Center for three days and three nights

js用while循环计算假如投资多年的利率为5%,试求从1000块增长到5000块,需要花费多少年
随机推荐
Multi table associated query -- 07 -- hash join
使用 Blackbox Exporter 测试网络连通性
Origin of forward slash and backslash
sql sever列名或所提供值的数目与表定义不匹配
volatile 和 synchronized 到底啥区别?
Win10 remote connection to ECS
Solve the problem of win10 wsl2 IP change
【软件工程】山东大学软件工程复习提纲
JDBC operation MySQL example
jupyter notebook文件目录
获取地址url中的query参数指定参数方法
Hutool symmetric encryption
JDBC操作Mysql示例
碎煤机crusher
File and multipartfile overview
One person manages 1000 servers? This automatic operation and maintenance tool must be mastered
Yolov6's fast and accurate target detection framework is open source
Xiaomi Interviewer: let's talk about the proficient Registration Center for three days and three nights
window右键管理
guava 定时任务