Examveda

Which built-in function is used to capitalize the first letter of a string?

A. capitalize()

B. upper()

C. title()

D. first_letter()

Answer: Option C

Solution (By Examveda Team)

The title() function in Python is used to capitalize the first letter of each word in a string. It returns a copy of the string with the first letter of each word capitalized. This function is particularly useful when you want to capitalize the first letter of each word in a sentence or a string.

This Question Belongs to Python Program >> Python Built In Functions

Join The Discussion

Related Questions on Python Built In Functions