-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtable.js
91 lines (75 loc) · 1.6 KB
/
table.js
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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
let workers=[
["tyler brooks",
"$2500",
"amature level",
],
["james spoonky",
"$3000",
"proffessional",
],
["emma star",
"$1500",
"entirely-level",
],
["dennis nicholas",
"$5000",
"expert(pro)",
],
["mrs.finley",
"$1000",
"entirely-level",
],
["ms.grace sophia",
"$2500",
"amature",
],
["mark",
"$3000",
"professional",
],
["emma wood",
"$5000",
"expert(pro)",
],
["William Tyler",
"$3500",
"professional",
],
["cheryl watson",
"$1200",
"entirely-level",
],
];
document.write("<table border='1px'><h1>CYBER-SECURITY COMPANY MONTHLY PAYROLL<h1>");
document.write("<tr>")
document.write("<th> S/N </th>")
document.write("<th> Name </th>")
document.write("<th> Amount </th>")
document.write("<th> Experience </th>")
document.write("<th> Email </th>")
document.write("</tr>");
for(let i=0; i<workers.length; i++){
const element= workers[i]
const Name=element[0]
const Amount=element[1]
const Experience=element[2]
const Email=element[3]
document.write("<tr>");
document.write(`<td>${i + 1}</td>`);
document.write(`<td>`+Name+`</td>`);
document.write(`<td>`+Amount+`</td>`);
document.write(`<td>`+Experience+`</td>`);
document.write(`<td>`+Email+`</td>`);
document.write("</tr>");
}
document.write('</table>');