Skip to content

Challenge Use Bracket Notation To Find The Nth Character In A String

Quincy Larson edited this page Aug 20, 2016 · 1 revision

Challenge Use Bracket Notation to Find the Nth Character in a String

You can also use bracket notation to get the character at other positions within a string.

Remember that computers start counting at 0, so the first character is actually the zeroth character.

var thirdLetterOfLastName = lastName[2];
Clone this wiki locally