forked from truecodersio/JavaScript_Operators
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathapp.js
More file actions
43 lines (34 loc) · 835 Bytes
/
app.js
File metadata and controls
43 lines (34 loc) · 835 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
40
41
42
43
console.log("Hello World!\n==========\n");
console.log(
"Follow the steps in the README.md file to complete the exercises:\n==========\n"
);
// Exercise 1
console.log("EXERCISE 1:\n==========\n");
// YOUR CODE HERE
let a = 20;
let b = 4;
let add = a + b;
let minus = a -b;
let multiply = a * b;
let divide = a / b;
// Exercise 2
console.log("EXERCISE 2:\n==========\n");
// YOUR CODE HERE
num + str ('1111')
num + str2 ('11eleven')
num + isPresent (12)
firstName + num ('Frodo11')
isPresent + str ('true11')
firstName + lastName ('FrodoBaggins')
// Exercise 3
console.log("EXERCISE 3:\n==========\n");
// YOUR CODE HERE
val == str (true)
val === str (false)
!isPresent (true)
("eleven" == str2 && val >=str) (false)
(!isPresent || isPresent) (true)
0 == false (true)
0 === false (false)
0 != false (false)
0 !== false (true)