i keep getting an error. i don’t know what is wrong here
Your code so far
let lastNameLength = 0;
const lastName = "Lovelace";
// Only change code below this line
lastNameLength = lastName;
Your browser information:
User Agent is:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/188.8.131.52 Safari/537.36
Link to the challenge:
Does this line make sense? You’re saying, in words, that the length of the string is the string itself.
You set the value of the required variable to the string itself not the length of the string.
" Use the
.length property to set
lastNameLength to the number of characters in
lastName . "
in your code you set `lastNameLength = lastName´
The exercise wants you to set the value of
lastNameLength “to the number of characters in last name” so:
Mod Edit: SOLUTION REMOVED
You are printing the numbers of characters in
But in your code the value of
lastNameLength is “Lovelace” and not the numbers of characters in said string.
I hope to have helped you,if not just say anything and ill try again.
It is great that you solved the challenge, but instead of posting your full working solution, it is best to stay focused on answering the original poster’s question(s) and help guide them with hints and suggestions to solve their own issues with the challenge.
We are trying to cut back on the number of spoiler solutions found on the forum and instead focus on helping other campers with their questions and definitely not posting full working solutions.
Thank you for editing for me and i’m sorry for infringing the rules.
Whenever i’m able to help someone, i won’t post the solution again .
Have a nice day
This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.