Python String isupper() MethodPython Functions


The isupper() method checks if all the string letters are uppercase.

Example

#!/usr/bin/python3
# -*- coding: UTF-8 -*-

str = "ABCDRFG"
print(str.isupper())

str = "aBCDEFG"
print(str.isupper())

Output:

True
False

Syntax

str.isupper()

Parameters

The method doesn’t take any parameters.

Return Value

It returns true or false.

© 2021 Programtips.org, all rights reserved. Privacy Policy | Contact Us