Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

c06/c06_10 #47

Open
utterances-bot opened this issue Jul 14, 2022 · 1 comment
Open

c06/c06_10 #47

utterances-bot opened this issue Jul 14, 2022 · 1 comment

Comments

@utterances-bot
Copy link

6.10 保持代码的简洁与可诗性 — Python黑魔法手册 1.0.0 documentation

https://magic.iswbm.com/c06/c06_10.html

Copy link

# ERROR
def function():
    if isinstance(a, b) or issubclass(b, a):
        returnTrue
    returnFalse
# CORRECT
def function():
    if isinstance(a, b) or issubclass(b, a):
        return True
    return False

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants