Use Bracket Notation to Find the First Character in a String.(can I)

Tell us what’s happening:
Describe your issue in detail here.
I have problem making the firstLetterOfLastName have the value of L

Your code so far

I think we could understand the issue better if you include your code. Yes, you can use bracket notation to access particular positions in a string - but when you do, bear in mind your using array indexes.

So str[4] works fine, but str["M"] won’t.

My code is there, you just need to prees the box where freecodecamp is written

that is the link to the challenge, your code is not visible there

1 Like

Your code is there in your browser, as it gets stored locally. But the only way we can see it is if you explicitly copy and paste it. Or if you don’t delete it when you click “ask for help.”