Ask coding questions

← Back to all posts
If and else statement is not working
Flyingcrabs (7)

So on line 37 the else statement is not working

Answered by Smart0ne (723) [earned 5 cycles]
View Answer
Comments
hotnewtop
Smart0ne (723)

(Line 19-22)

    while True:
        os.system("clear")
        cprint("Username:", "green")
        Username = input("")

You are stuck in an infinite loop here. Fix the indentation.

IcynDevz (762)

The indentation is wrong. Add one more space before the cprint("Wrong USERNAME please report if you think this is a mistake.", "red") and time.sleep(5)