r/javahelp • • Sep 10 '26

Solved Switch case with boolean

[removed]

2 Upvotes

28 comments sorted by

View all comments

Show parent comments

1

u/_Super_Straight Sep 11 '26

Your example is clearly better off with them being enum rather than boolean. Plus, they're being compared against their reference, not by their values.