-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy path10. Q10.js
More file actions
38 lines (36 loc) · 1.03 KB
/
10. Q10.js
File metadata and controls
38 lines (36 loc) · 1.03 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
// 10. Figure out the result of the following comparison expression first without using console.log(). After you decide the result confirm it using console.log()
// - 4 > 3
// - 4 >= 3
// - 4 < 3
// - 4 <= 3
// - 4 == 4
// - 4 === 4
// - 4 != 4
// - 4 !== 4
// - 4 != '4'
// - 4 == '4'
// - 4 === '4'
// - Find the length of python and jargon and make a falsy comparison statement.
// My Answers -
// 4 > 3 - true
// 4 >= 3 - true
// 4 < 3 - false
// 4 <= 3 - false
// 4 == 4 - true
// 4 === 4 - true
// 4 != 4 - false
// 4 !== 4 - false
// 4 != '4' - false
// 4 == '4' - true
// 4 === '4' - false
console.log(`4 > 3 is ${4 > 3}`);
console.log(`4 >= 3 is ${4 >= 3}`);
console.log(`4 < 3 is ${4 < 3}`);
console.log(`4 <= 3 is ${4 <= 3}`);
console.log(`4 == 4 is ${4 == 4}`);
console.log(`4 === 4 is ${4 === 4}`);
console.log(`4 != 4 is ${4 != 4}`);
console.log(`4 !== 4 is ${4 !== 4}`);
console.log(`4 != '4' is ${4 != "4"}`);
console.log(`4 == '4' is ${4 == "4"}`);
console.log(`4 === '4' is ${4 === "4"}`);