Python String title() Function
The String title()
method returns a new string with the first character of each word to uppercase and the remaining characters to lowercase. It is particularly useful for formatting strings as titles or headers.
note
The method does not change the original string.
Syntax
my_string.title()
title() Parameters
Python String title()
function does not take any parameters.
title() Return Value
Python String title()
function returns a new string with the first character of each word capitalized and all other characters in lowercase.