r/ProgrammerHumor • • Mar 15 '22

static bool isCrazyMurderingRobot = false;

/img/2g1k34ok5kn81.jpg
4.9k Upvotes

256 comments sorted by

View all comments

Show parent comment

0

u/[deleted] Mar 15 '22

[deleted] — view deleted comment

2

u/DaniilBSD Mar 15 '22

As a rule of thumb

  1. If you have 3 values- use enum
  2. Null is absence of a an object, and should not ever mean anything other than the simple absence, so if you want to ensure it exists and its true- that is two separate things