-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathjavascriptstudy.html
More file actions
155 lines (152 loc) · 9.63 KB
/
Copy pathjavascriptstudy.html
File metadata and controls
155 lines (152 loc) · 9.63 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
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
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="stylesheet" href="../css/study.css">
<script defer src="../js/study.js"></script>
<script type="module" src="https://unpkg.com/ionicons@5.5.2/dist/ionicons/ionicons.esm.js"></script>
<script nomodule src="https://unpkg.com/ionicons@5.5.2/dist/ionicons/ionicons.js"></script>
<title>JAVASCRIPT REVIEW</title>
</head>
<body>
<section>
<nav class="navbar">
<div class = "brand-title">JAVASCRIPT</div>
<a href = "#" class = "toggle-button">
<span class = "bar"></span>
<span class = "bar"></span>
<span class = "bar"></span>
</a>
<div class = "navbar-links">
<ul>
<li><a href = "index.html">Home</a></li>
<li><a href = "htmlstudy.html">HTML</a></li>
<li><a href = "cssstudy.html">CSS</a></li>
<li><a href = "flexboxstudy.html">Flexbox/ Grid</a></li>
<!-- <li><a href = "#">Javascript</a></li> -->
</ul>
</div>
</nav>
<div class = "title"> <h1>Music</h1> </div>
<div id = "music-player">
<img src="../images/backButton.png" alt="" id = "previous" class = "back-forward">
<img src="../images/play.png" alt="" id = "icon" >
<img src="../images/nextButton.png" alt="" id = "next" class = "back-forward">
</div>
<div class="container">
<div class="accordion">
<div class="accordion-item" id = "question1">
<a class = "accordion-link" href="#question1">
In JavaScript, what is a block of statement?
<ion-icon name="add-outline" class = "add"></ion-icon>
<ion-icon name="remove-outline" class = "remove"></ion-icon>
</a>
<div class="answer">
<p>A block of statement can be understand as the set of the zero or more statements. In general, a block of statement has common definition "which combines one or a number of statements into a single statement for ease.</p>
</div>
</div>
<div class="accordion-item" id = "question2">
<a class = "accordion-link" href="#question2">
When interpreter encounters an empty statements, what it will do?
<ion-icon name="add-outline" class = "add"></ion-icon>
<ion-icon name="remove-outline" class = "remove"></ion-icon>
</a>
<div class="answer">
<p>In JavaScript, when the interpreter encounters a empty statements it normally ignores or not response to that empty statement. The empty statements also sometimes very useful like we use the empty statements for creating loop for nothing.</p>
</div>
</div>
<div class="accordion-item" id = "question3">
<a class = "accordion-link" href="#question3">
What are the "function" and " var" known as?
<ion-icon name="add-outline" class = "add"></ion-icon>
<ion-icon name="remove-outline" class = "remove"></ion-icon>
</a>
<div class="answer">
<p>The "function" and "var" both are the Declaration statements. These both are used for defining, and declaring variable, function in anywhere in the program.
</p>
</div>
</div>
<div class="accordion-item" id = "question4">
<a class = "accordion-link" href="#question4">
Which variable takes precedence over the others if the names are the same?
<ion-icon name="add-outline" class = "add"></ion-icon>
<ion-icon name="remove-outline" class = "remove"></ion-icon>
</a>
<div class="answer">
<p>In JavaScript, the local variable takes precedence over the global variable if the name of both local and global variables is the same.!</p>
</div>
</div>
<div class="accordion-item" id = "question5">
<a class = "accordion-link" href="#question5">
What is the correct way for calling a JavaScript code?
<ion-icon name="add-outline" class = "add"></ion-icon>
<ion-icon name="remove-outline" class = "remove"></ion-icon>
</a>
<div class="answer">
<p>The JavaScript code can be called simply by making the function call to the element on which the JavaScript code execution has to be run. There are several other ways to call JavaScript code such as submit, onclick, and onload, etc.</p>
</div>
</div>
<div class="accordion-item" id = "question6">
<a class = "accordion-link" href="#question6">
Which javascript variable is volatile?
<ion-icon name="add-outline" class = "add"></ion-icon>
<ion-icon name="remove-outline" class = "remove"></ion-icon>
</a>
<div class="answer">
<p>The variables whose value can be modified that kind of variable are known as Mutable variable. In the JavaScript, only arrays and objects are mutable but not the primitive values.</p>
</div>
</div>
<div class="accordion-item" id = "question7">
<a class = "accordion-link" href="#question7">
When there is an indefinite or an infinite value during an arithmetic computation in a program, what does javascript print?
<ion-icon name="add-outline" class = "add"></ion-icon>
<ion-icon name="remove-outline" class = "remove"></ion-icon>
</a>
<div class="answer">
<p>In the case, where the result of any arithmetic expression is beyond the largest represent-able number,JavaScript prints the infinity. Similarly, if the result of any numerical operation is beyond the largest negative number, JavaScript prints negative infinity.
</p>
</div>
</div>
<div class="accordion-item" id = "question8">
<a class = "accordion-link" href="#question8">
In JavaScript, what is not considered as an error?
<ion-icon name="add-outline" class = "add"></ion-icon>
<ion-icon name="remove-outline" class = "remove"></ion-icon>
</a>
<div class="answer">
<p>Yes, you heard right that division of any integer by zero is not an error in the JavaScript. It just prints the infinity as a result. However, there is an exception in JavaScript, dividing zero with zero will not have any defined number/value so, the result of this specific operation is a special value "Not a Number" or NaN and printed as NaN.</p>
</div>
</div>
<div class="accordion-item" id = "question9">
<a class = "accordion-link" href="#question9">
In JavaScript, what will be used for calling the function definition expression?
<ion-icon name="add-outline" class = "add"></ion-icon>
<ion-icon name="remove-outline" class = "remove"></ion-icon>
</a>
<div class="answer">
<p>A function definition expression is a kind of "function literal' just like as the object initializer is a kind of "object literal". The function definition expression or we can say a function literalconsists of the keyword Function, followed by the set of identifiers or parameters names that are separated by commas inside the parenthesis, and a small block of JavaScript code which we normally called function body/definition enclosed in the curly braces.
</p>
</div>
</div>
<div class="accordion-item" id = "question10">
<a class = "accordion-link" href="#question10">
What is the property of the primary expression?
<ion-icon name="add-outline" class = "add"></ion-icon>
<ion-icon name="remove-outline" class = "remove"></ion-icon>
</a>
<div class="answer">
<p>In JavaScript, the primary expressions also called simplest expressions are those standalone expressions, which do not include any of the simpler expressions. The variable, constant or literal values and certain language keywords are the basic examples of the primary expressions.</p>
</div>
</div>
</div>
</div>
</div>
<div id = userColor>
<h1>Don't like the background color?</h1>
<h2 id = "change-it"= >Click here to change it</h2>
</div>
</section>
</body>
</html>