5 ms·
Is the 'married == True' instead of just 'married' is done on purpose to trigger me ?
by Hypergraphe 5y ago
Is the 'married == True' instead of just 'married' is done on purpose to trigger me ?
- deleted 5y ago[deleted]
- Thiez 5y agoYou can go further with some simple rewriting rules. For instance, if (condition) { variable = true; } can be rewritten as variable |= condition; So if we're streamlining the sexism we end up with a more pleasing hasChildren |= gender == "female" && married && age >= 30;
- vidarh 5y agoYou're assuming you know which language this made-up code was written for.
- Hypergraphe 5y agoNice, I would add some parenthesis after |= to enhance readability ;)
- deleted 5y ago[deleted]
- shockeychap 5y agoNice. :-)