In order to get the last letter of a string, you can subtract one from the string's length. For example, if var firstName = "Charles", you can get the value of the last letter of the string by using ...
You can find the length of a String value by writing .length after the string variable or string literal. "Alan Peter".length; // 10 For example, if we created a variable var firstName = "Charles", we ...