当前位置:网站首页>JS example print the number and sum of multiples of all 7 between 1-100
JS example print the number and sum of multiples of all 7 between 1-100
2022-06-27 07:35:00 【I am the sun?】
Code :
<!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> Print 1-100 Between all 7 Number and sum of multiples of </title>
<script type="text/javascript">
var sum = 0,count = 0;
for(var i = 1;i <= 100;i++){
if(i % 7 == 0){
console.log(i);
sum+=i;
count+=1;
}
}
console.log("7 Number of multiples of :" + count);
console.log("7 The sum of multiples of :" + sum);
</script>
</head>
<body>
</body>
</html>
Running results :
边栏推荐
猜你喜欢

yarn create vite 报错 ‘D:\Program‘ 不是内部或外部命令,也不是可运行的程序 或批处理文件

mssql如何使用语句导出并删除多表数据

Solve the problem of win10 wsl2 IP change

DMU software syntax highlighting VIM setting -- Learning Notes 6

Cookie encryption 6

What is the difference between volatile and synchronized?

Multi table associated query -- 07 -- hash join

Memory barrier store buffer, invalid queue
![[openairinterface5g] rrcsetupcomplete for RRC NR resolution](/img/61/2136dc37b98260e09f3be9979492b1.jpg)
[openairinterface5g] rrcsetupcomplete for RRC NR resolution

Cookie encryption 7 fidder analysis phase
随机推荐
guava 教程收集一些案例慢慢写 google工具类
语音合成:Tacotron详解【端到端语音合成模型】【与传统语音合成相比,它没有复杂的语音学和声学特征模块,而是仅用<文本序列,语音声谱>配对数据集对神经网络进行训练,因此简化了很多流程】
在线文本数字识别列表求和工具
How torch.gather works
Memory barrier store buffer, invalid queue
Interviewer: you use Lombok every day. What is its principle? I can't answer
js中如何查看程序运行时间(计时器)
Idea方法模板
boundvalueops和opsforvalue区别
延时队列`DelayQueue`
[Software Engineering] software engineering review outline of Shandong University
File and multipartfile overview
JDBC operation MySQL example
[Kevin's third play in a row] is rust really slower than C? Further analyze queen micro assessment
volatile 和 synchronized 到底啥区别?
Speech signal feature extraction process: input speech signal - framing, pre emphasis, windowing, fft- > STFT spectrum (including amplitude and phase) - square the complex number - > amplitude spectru
Sword finger offer 07 Rebuild binary tree
cookie加密7 fidder分析阶段
log4j:WARN No such property [zipPermission] in org. apache. log4j. RollingFileAppender.
Guava tutorial collect some cases and write Google tool classes slowly