Last Updated on June 17, 2021 by Roshan Parihar
In this tutorial, learn how to convert all string to lowercase in Python. The short answer is: use the Python lower()
function to make string characters lowercase. Change from uppercase to lowercase for all the strings characters.
You have a string with many characters in the uppercase format. The characters do not look in a better way to display string in the output. So, in that case, you have to change the string to the lowercase from uppercase. You may also like to read how to combine two string variables in Python.
Convert All String to Lowercase Using Python
If you want to convert the uppercase characters to the lowercase in Python. You can use the Python lower()
function which converts all the string to lowercase. This is the simple method of changing camel case characters to small letter characters.
1 2 |
myStr = "How Are You TODAY?"; print(myStr.lower()); |
Output
The above example showing the output of the lower()
function of Python. The output contains no camel case characters in the given string after conversion. Here, before the conversion, the last string word contains all letters in a capital case. The Python also converts these letters to the small letter using lower()
.
If you want to convert the string to uppercase characters. You can read our post based on Change String To Uppercase Characters Using Python.
DOWNLOAD Free PYTHON CHEAT SHEET
You may also like to read
- How to remove all whitespace from a string using Python
- Create a string variable in Python.
- Access string character by index using Python
I hope you like this post on how to convert all strings to lowercase using Python.
References