JPDev@programming.dev to Programmer Humor@programming.dev · 10 months agoTypeScript is Quantum Readyprogramming.devimagemessage-square32fedilinkarrow-up1554arrow-down17
arrow-up1547arrow-down1imageTypeScript is Quantum Readyprogramming.devJPDev@programming.dev to Programmer Humor@programming.dev · 10 months agomessage-square32fedilink
minus-squareOctopus1348linkfedilinkarrow-up3·10 months agoIt’s much more readable when you use else depending on the checks. You can still use return in an else block. def Allowed() if name == "Octopus1348": return True elif name == "Bobert": return True else: return "You are not allowed to use this script." print(Allowed()) `
It’s much more readable when you use else depending on the checks. You can still use return in an else block.
def Allowed()
print(Allowed())
`