Skip to content

Commit f504687

Browse files
author
russom
committed
Remove unreachable and redundant code.
1 parent 4707f5a commit f504687

1 file changed

Lines changed: 0 additions & 11 deletions

File tree

‎dead-code/exercise-1.js‎

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,6 @@
11
// Find the instances of unreachable and redundant code - remove them!
22
// The sayHello function should continue to work for any reasonable input it's given.
33

4-
let testName = "Jerry";
5-
const greeting = "hello";
6-
74
function sayHello(greeting, name) {
8-
95
return `${greeting}, ${name}!`;
10-
116
}
12-
13-
testName = "Aman";
14-
15-
const greetingMessage = sayHello(greeting, testName);
16-
17-
console.log(greetingMessage); // 'hello, Aman!'

0 commit comments

Comments
 (0)