-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
53 lines (52 loc) · 1.2 KB
/
index.html
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
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Practice</title>
<script>
//JavaScript class assignments PIAIC 29 march 2020
var abc = "Abc";
var x = 123;
var arr = ["apple", " Banana", " Pineapple"];
var bool = true;
var obj = {
Name: "Aisha",
SurName: "Khan",
Class: "CNC"
};
if (abc) {
document.write(abc + " " + "def");
}
document.write("<br/>");
if (x) {
document.write(x + 2);
}
document.write("<br/>");
if (bool) {
document.write((bool = !true));
}
document.write("<br/>");
if (arr) {
document.write(arr + arr.push("kivi"));
}
document.write("<br/>");
if (obj) {
obj.gender = "female";
document.write(JSON.stringify(obj));
}
//JavaScript class assignments PIAIC 29 march 2020 End
</script>
<style>
.abc {
width: 100%;
height: auto;
text-align: center;
}
</style>
</head>
<body>
<div class="abc">
<h1>Periodic table</h1>
</div>
</body>
</html>