Python String islower() Method (original) (raw)

Last Updated : 11 Nov, 2024

The **islower() method in Python checks if all characters in a string are lowercase. It returns **True if all alphabetic characters are lowercase, otherwise, it returns **False, if there is at least one uppercase letter.

Let’s look at a quick example of using the islower() method.

Python `

s = "hello" res = s.islower() print(res)

`

**Explanation: The string **s contains only lowercase alphabetic characters, so **islower() returns **True.

Table of Content

Syntax of islower()

s.islower()

Parameter:

Return Value:

Example of islower()

Let’s look at a few examples of islower() method.

Python `

s1 = "hello" res1 = s1.islower() print(res1)

s2 = "Hello" res2 = s2.islower() print(res2)

s3 = "hello123" res3 = s3.islower() print(res3)

s4 = "" res4 = s4.islower() print(res4)

s5 = "123@" res5 = s5.islower() print(res5)

`

Output

True False True False False

**Explanation:

**Related Articles:

Similar Reads