forked from HackYourFuture/JavaScript1
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathapp.js
More file actions
80 lines (68 loc) · 2 KB
/
app.js
File metadata and controls
80 lines (68 loc) · 2 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
let englishGreeting = "Hello, World!"
console.log(englishGreeting);
let kurdishGreeting = "Silav, Cihan!"
console.log(kurdishGreeting);
let dutchGreeting = "Hoi, Wereld!"
console.log(dutchGreeting);
let me = "I'm awesome!"
console.log(me);
let x;
console.log("I think the value of x is a number");
console.log("The value of x is 6");
let x = 6;
console.log("I think the value of x is 6");
console.log(x);
let y ="Sivan";
console.log("I think the value of y is a name");
console.log(y);
const y = "Hassam";
console.log("There will be an error because now I have
the same variable with different values.");
console.log(y);
const z = 7.25;
console.log(z);
const a = z;
console.log(a);
var round =Math.round(7.25);
console.log(round)
let arrays =
console.log("I think variable arrays is related to animals");
console.log(arrays);
let myFavoriteAnimals = [cat, dog, sheep];
console.log(myFavoriteAnimals);
let favoriteAnimalOfDaan = "baby pig";
const animals = "myFavoriteAnimals" + "" + "favoriteAnimalOfDaan";
console.log(animals);
let myString = "this is a test";
console.log(myString);
console.log(myString ["length"]);
let num = 11;
let address = "Huygenhoekring";
let supermarkets = ["Lidl", "Dekka", "Jumbo"];
let booleans = true, false, true;
console.log(num);
console.log(address);
console.log(supermarkets);
console.log(booleans);
console.log(I think the type of num is number,
type of address is string,
type of supermarkets is array and
type of booleans is boolean.);
console.log(typeof num);
console.log(typeof supermarkets);
console.log(typeof booleans);
console.log(typeof address);
if (num != address) {
console.log("num is a number and address is a string");
}
let s = 7;
let v = 3;
let h = s % 3;
console.log(s % h);
console.log(s % v);
console.log(v % h);
const mix = [5, "Shvan"];
console.log(mix);
var maxNumber = Math.pow(6/0);
if (maxNumber === Infinity)
console.log(0 / maxNumber);