-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.js
More file actions
45 lines (30 loc) · 1009 Bytes
/
Copy pathmain.js
File metadata and controls
45 lines (30 loc) · 1009 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
44
var userName = 'Jon';
console.log(userName);
if (userName === 'Jon') {
console.log('Hello, Jon!');
} else {
console.log('Hello!');
}
var userQuestion = 'Will today be a great day to learn code?';
console.log(userQuestion);
var randomNumber = Math.floor(Math.random() * 8);
console.log(randomNumber);
var eightBall = '';
if (randomNumber === 0) {
console.log('It is certain');
} else if
(randomNumber === 1) {
console.log('It is decidedly so');
} else if (randomNumber === 2) {
console.log('Reply hazy cuz im feelin lazy, try again');
} else if (randomNumber === 3) {
console.log('Cant Predict right');
} else if (randomNumber === 4) {
console.log('Dont count on it');
} else if (randomNumber === 5) {
console.log('My sources say no but you should anyways');
} else if (randomNumber === 6) {
console.log('Outlook not so good');
} else if (randomNumber === 7) {
console.log('Yeah, and you should wear your sunglasses inside because your future is so bright');
}