Python‎ > ‎str‎ > ‎

str.lower()


Definition
Return a copy of the string converted to lowercase.

Syntax
str.lower() -> str

Parameters
str=string

Example
 >>> "python lake".lower()
'python lake'
>>> "Python Lake".lower()
'python lake'
>>>

is not
The method returns negative in operator.is_not:
 >>> "Python Lake".lower() is not "python lake".lower()
True
>>> "Python Lake".lower() is not "python lake"
True

for statement
Lambda function is used to convert the string values in set.
name={"python","Lake", "research", "Centre"}
for a in map(lambda x: x.lower(),name):
    print(a)
>>> 
centre
research
lake
python
>>> 

Comments