python how to make first letter capitalize and others lower code example
Example 1: how do you change a string to only uppercase in python
original = Hello, World!
#both of these work
upper = original.upper()
upper = upper(original)
Example 2: capitalize first letter of each word python
"hello world".title()
'Hello World'
>>> u"hello world".title()
u'Hello World'