Skip to content

Commit d3921b1

Browse files
committed
initials variable declared
1 parent c826f5e commit d3921b1

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

Sprint-1/1-key-exercises/2-initials.js

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,6 @@ let firstName = "Creola";
22
let middleName = "Katherine";
33
let lastName = "Johnson";
44

5-
// Declare a variable called initials that stores the first character of each string.
6-
// This should produce the string "CKJ", but you must not write the characters C, K, or J in the code of your solution.
7-
8-
let initials = ``;
9-
10-
// https://www.google.com/search?q=get+first+character+of+string+mdn
5+
let initials = firstName[0] + middleName[0] + lastName[0];
116

7+
console.log(initials);

0 commit comments

Comments
 (0)