개요
- 파이썬 ucfirst()
- 내장 함수 아님
- 문자열의 첫글자는 대문자로 변환하고, 나머지는 그대로 둔다.
s = 'hello world!'
print ( s[0].upper() + s[1:] ) # Hello world!
s = 'HELLO WORLD!'
print ( s[0].upper() + s[1:] ) # HELLO WORLD!
s = 'hello world!'
print ( s[0].upper() + s[1:] ) # Hello world!
s = 'HELLO WORLD!'
print ( s[0].upper() + s[1:] ) # HELLO WORLD!