-
Notifications
You must be signed in to change notification settings - Fork 20
Expand file tree
/
Copy pathaula03.01_exercicio.html
More file actions
39 lines (24 loc) · 846 Bytes
/
aula03.01_exercicio.html
File metadata and controls
39 lines (24 loc) · 846 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
<!doctype html>
<html>
<head>
<title>Logica de Programação Javascript</title>
<meta charset="utf-8">
</head>
<body>
<h1>Lógica de programação com Javascript</h1>
</body>
<script>
var numero = prompt('digite um numero');
numero = parseFloat(numero);
var indice = 0;
//repita até que indic4e seja <= 1000
while(indice <= 1000){
document.write( numero + ' x '+ indice +' = '+ (numero * indice) +' <br>');
if(indice % 10 === 0 && indice > 0){
document.write('<hr>');
}
indice = indice + 1;
}
document.write('saiu do loop');
</script>
</html>