Python String islower() Method
The islower() method detects whether the string consists of lowercase letters.
Python String islower() Syntax
islower() method syntax:
str.islower()
Python String islower() Parameters
- None.
Python String islower() Return Value
Returns True if the string contains at least one case-sensitive character and all those (case-sensitive) characters are lowercase, otherwise returns False.
Python String islower() Example#1
The following example shows an example of the islower() method.
#!/usr/bin/python3
str1 = "APIDEMOS example....wow!"
print (str1.islower())
str1 = "apidemos example....wow!"
print (str1.islower())
islow_str = "apidemos"
not_islow = "ApiDemos"
# checking which string is completely lower
print ("Is", islow_str, "full lower ? : " + str(islow_str.islower()))
print ("Is", not_islow, "full lower ? : " + str(not_islow.islower()))
Output: