The function retrieves and returns the last character of a given input string.
