문자열 입력을 split 함수로 list로 변형한 후, list[-1] return함.
class Solution: def lengthOfLastWord(self, s: str) -> int: s = s.split() return len(s[-1])