• I can't understand why the code does not pass the

Question related to mission All Upper I

 

I can't understand why the code does not pass the test, tell me

def isallupper(text: str) -> bool: # your code here

if text != '':
    b = text.isupper()
    return b
if text == '':
    b = '' in text
    return b

if name == 'main': print("Example:") print(isallupper('ALL UPPER'))

# These "asserts" are used for self-checking and not for an auto-testing
assert is_all_upper('ALL UPPER') == True
assert is_all_upper('all lower') == False
assert is_all_upper('mixed UPPER and lower') == False
assert is_all_upper('') == True
print("Coding complete? Click 'Check' to earn cool rewards!")