Python string | capwords() method
In Python, string capwords() method is used to capitalize all the words in the string using spilt() method. Syntax: string.capwords(string, sep=None) Return Value: Returns a… Read More »
In Python, string capwords() method is used to capitalize all the words in the string using spilt() method. Syntax: string.capwords(string, sep=None) Return Value: Returns a… Read More »
In Python3, string.octdigits is a pre-initialized string used as string constant. In Python, string.octdigits will give the octadecimal letters ‘01234567’. Syntax : string.octdigits Parameters :… Read More »
In Python3, string.punctuation is a pre-initialized string used as string constant. In Python, string.punctuation will give the all sets of punctuation. Syntax : string.punctuation Parameters… Read More »
In Python3, string.whitespace is a pre-initialized string used as string constant. In Python, string.whitespace will give the characters space, tab, linefeed, return, formfeed, and vertical… Read More »
Given a string of letters, write a python program to sort the given string in an alphabetical order. Examples: Input : PYTHON Output : HNOPTY… Read More »
lstrip() method returns a copy of the string with leading characters removed (based on the string argument passed). If no argument is passed, it removes… Read More »
translate() returns a string that is modified string of givens string according to given translation mappings. There are two ways to translate : Providing a… Read More »
lower() method converts all uppercase characters in a string into lowercase characters and returns it. Syntax : string.lower() Parameters : The lower() method doesn’t take… Read More »
rstrip() method returns a copy of the string with trailing characters removed (based on the string argument passed). If no argument is passed, it removes… Read More »
upper() method converts all lowercase characters in a string into uppercase characters and returns it Syntax : string.upper() Parameters : The upper() method doesn’t take… Read More »
Python has many utility functions in its libraries that always help us to achieve some common day-day task. Let’s see the working of string isupper()… Read More »
Python has many utility functions in its libraries that always help us to achieve some common day-day task. Let’s see the working of string islower()… Read More »