capitalize specific letter in python code example
Example 1: python capitalize the entire string
message="hi"
print(message)
print(message.upper())
Example 2: how to capitalize the first letter in a list python
singers = ['johnny rotten', 'eddie vedder', 'kurt kobain', 'chris cornell', 'micheal phillip jagger']
singers = [singer.capitalize() for singer in singers]
print(singers)
#instead of capitalize use title() to have each word start with capital letter