Skip to content

Commit bb906ad

Browse files
committed
practicing
1 parent 45d9b80 commit bb906ad

5 files changed

Lines changed: 33 additions & 0 deletions

File tree

‎prep/comparison.js‎

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
console.log("hello" === "hello");
2+
3+
// 2
4+
console.log("CYF" === "cyf");
5+
6+
// 3
7+
const homeTown = "Newcastle";
8+
9+
console.log(homeTown === "Liverpool");
10+
11+
// 4
12+
console.log(42 !== "42");

‎prep/facts.js‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
console.log("collaborating in Github develops Github skills");

‎prep/greeting.js‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
const greeting = "Hello there";
2+
let name = "Alicia";
3+
name = "Aklilu";
4+
//console.log(`${greeting}, ${name}`);
5+
console.log(greeting + "," + name);

‎prep/hello_world.js‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
console.log("Hello World!");

‎prep/passwordChecker.js‎

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
const password = "secretword123";
2+
const userInput = "thisiswrong";
3+
const adminPassword = "override";
4+
let response = "";
5+
6+
if (userInput === password) {
7+
response = "Correct password entered";
8+
} else if (userInput === adminPassword) {
9+
response = "Admin access granted";
10+
} else {
11+
response = "Incorrect password!";
12+
}
13+
14+
console.log(response);

0 commit comments

Comments
 (0)