News for hackers. Stuff that matters.
Re:Understanding Python through its builtins by andi999 on Tuesday October 12, 2021 @12:25AM (#28836040)
What do you mean by depends on assert for correctness? How?
Re:Understanding Python through its builtins by Doxin on Tuesday October 12, 2021 @07:30AM (#28838464)

    get_president_inside_bunker()
    assert president_is_inside_bunker()
    close_bunker_doors()
    assert bunker_doors_are_closed()
    send_nukes()
With asserts enabled this is fine. With asserts disabled you might start sending nukes while the president is still outside or the doors to the bunker are still open.
Re:Understanding Python through its builtins by andi999 on Wednesday October 13, 2021 @05:10AM (#28849923)
Thanks! I never thought anybody would do such a thing.
Re:Understanding Python through its builtins by Doxin on Thursday October 14, 2021 @04:07AM (#28861655)
No one should, but it happens.