Learn Introductory JavaScript by Building a Pyramid Generator - Step 12

Tell us what’s happening:

When i check my code it gives me this message “You should assign the string “teacher” to the profession variable.” even though I’m positive i did it right.

Your code so far

let character = "Hello";

// User Editable Region

let profession = "teacher";
let age = ;
console.log(profession);
console.log(age);

// User Editable Region

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/126.0.0.0 Safari/537.36

Challenge Information:

Learn Introductory JavaScript by Building a Pyramid Generator - Step 12

The string "teacher" does appear to be assigned to the variable profession correctly, but the next line has an error that prevents the code from running. This is probably what is causing the test to fail.

1 Like

Do not initialize the variable age.

1 Like

Worked perfectly. Thank you so much.

Thank you for the help. Much appreciated.

1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.