xxxxxxxxxx
# plz suscribe to my youtube channel -->
# https://www.youtube.com/channel/UC-sfqidn2fKZslHWnm5qe-A
Text = "python is easy"
print(Text.capitalize())
####output####
Python is easy
xxxxxxxxxx
text ="welcome to PYTHON Tutorial"
# capitalizes the first letter in string
# and keeps the rest of the string in lowercase
captialized_text= text.capitalize()
print(captialized_text)
xxxxxxxxxx
capitalize() - Converts the first character to upper case # e.g. "grepper".capitalize() => "Grepper"
xxxxxxxxxx
import string
S = "All animals are equal but some animals are more equal than others."
#capitalize all words in string S
print(string.capwords(S))
xxxxxxxxxx
x = txt = 'hi this is hussein asadi from iran '
x = txt.capitalize()
print (x)