Python String lower() Method

Converts all characters in a string to lowercase

Usage

The lower() method returns a copy of the string with all the characters converted to lowercase.

The method does not change the original string.

Syntax

string.lower()

Examples

Example: Convert all characters to lowercase

S = 'Hello, World!'
x = S.lower()
print(x)	# hello, world!

lower() method ignores numbers and special characters in a string.

Example:

S = '123 ABC $@%'
x = S.lower()
print(x)	# 123 abc $@%