Skip to content

equality to 10 checked twice #6

Description

@michaelaye

left_status = (100 if status_tmp == 10 else (status_tmp * 10 + 5 if status_tmp <= 10 else -1))

I believe the 2nd comparison should be simply status_tmp <10 because you check for ==10 before.
It doesn't harm, but confuses the reading of the code.

Thanks for this, very interesting!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions