Python title() method
Description
The Python title() method returns a "title-cased" string, meaning all words start with an uppercase letter and all other letters are lowercase (see istitle()).
Syntax
Syntax of the title() method:
str.title();
Parameters
- NA.
Return Value
Returns a "title-cased" string, meaning all words start with an uppercase letter.
Example
The following example shows how to use the title() function:
#!/usr/bin/python
str = "this is string example....wow!!!";
print str.title();
The output of the above example is:
This Is String Example....Wow!!!
Python Strings