Python3 islower() Method

Python3 字符串Python3 Strings


Description

The islower() method checks whether the string consists of lowercase letters.

Syntax

Syntax of the islower() method:

str.islower()

Parameters

  • None.

Return Value

Returns True if the string contains at least one case-sensitive character and all these (case-sensitive) characters are lowercase; otherwise, returns False.

Example

The following example demonstrates the islower() method:

Example

#!/usr/bin/python3

str = "EXAMPLE example....wow!!!"
print (str.islower())

str = "example example....wow!!!"
print (str.islower())

The output of the above example is as follows:

False
True

Python3 字符串Python3 Strings

Other Extensions