Back to Freecodecamp

Step 12

curriculum/challenges/english/blocks/learn-introductory-javascript-by-building-a-pyramid-generator/660ef55dd468079679ee0092.md

latest1016 B
Original Source

--description--

You are now ready to declare your next variable. Remove both console.log statements, and the character reassignment.

Also remove your secondCharacter variable, but leave the character initialization unchanged.

--hints--

You should not have any console.log() statements in your code.

js
assert.notMatch(__helpers.removeJSComments(code), /console/);

You should not reassign the value of character.

js
assert.isAtMost(__helpers.removeJSComments(code).match(/character\s*=/g).length, 1);

Your character variable should have the value "Hello".

js
assert.equal(character, "Hello");

You should not have a secondCharacter variable.

js
assert.notMatch(__helpers.removeJSComments(code), /secondCharacter/);

--seed--

--seed-contents--

js
--fcc-editable-region--
let character = 'Hello';
console.log(character);
character = "World";
let secondCharacter;
secondCharacter = character;
console.log(secondCharacter);
--fcc-editable-region--