Clean Code wrote:Every time you express yourself in code, you should pat yourself on the back. Every time you write a comment, you should grimace and feel the failure of your ability of expression.
Campbell Ritchie wrote:Why is he mixing & and &&?
Campbell Ritchie wrote:There is a design question there. Where are the rules which decide whether the Employee is eligible? Are they inside the Employee class?. ... Or are they defined in the benefits class?
No, he isn't, because otherwise it would fail to compile when combined with the && operator which requires a boolean on both sides.
Ron McLeod wrote: . . . He is performing a bitwise operation using HOURLY_FLAG as a mask to get the bit . . .