put the first letter of a string to the last javascript code example Example: javascript last character of string var lastChar = myString[myString.length -1];