-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtest.html
More file actions
54 lines (50 loc) · 1.38 KB
/
test.html
File metadata and controls
54 lines (50 loc) · 1.38 KB
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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
<!---->
<script src="test.js"></script>
<script>
//
/* */
// alert(100000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000 + 100)
// let star = ''
// for (let i = 1; i < 10; i++) {
// for (let j = 1; j <= i; j++) {
// star += '*'
// }
// star +='\n'
// }
// console.log(star)
// const MAXROW = 10
// const MAXCOL = 2*MAXROW - 1
// let star = ''
// for (let row = 1; row <= MAXROW; row++) {
// for (let col = 1; col <= MAXCOL; col++) {
// if (col <= MAXROW-row || col >= MAXROW+row) {
// star += ' '
// } else {
// star += '*'
// }
// }
// star +='\n'
// }
// console.log(star)
let output = ''
for (let i = 0; i<4; i++) {
for (let j=4; j>i; j--) {
output += ' ';
}
for (let k=0; k<2*i-1;k++) {
output += '*';
}
output += '\n';
}
console.log(output)
</script>
</head>
<body>
</body>
</html>