this post was submitted on 28 Oct 2024
504 points (98.3% liked)

Programming Humor

2662 readers
3 users here now

Related Communities !programmerhumor@lemmy.ml !programmer_humor@programming.dev !programmerhumor@kbin.social !programming_horror@programming.dev

Other Programming Communities !programming@beehaw.org !programming@programming.dev !programming@lemmy.ml !programming@kbin.social !learn_programming@programming.dev !functional_programming@programming.dev !embedded_prog@lemmy.ml

founded 1 year ago
MODERATORS
 
you are viewing a single comment's thread
view the rest of the comments
[–] cyborganism@lemmy.ca 18 points 2 weeks ago (1 children)

You can tell they're amateurs. It's not obfuscated enough. They won't be able to keep their job.

[–] Serinus@lemmy.world 19 points 2 weeks ago (1 children)

They clearly need an abstract boolean comparison factory.

[–] marcos@lemmy.world 21 points 2 weeks ago* (last edited 2 weeks ago) (1 children)
var CompareBooleans = new ComparatorFactory().BooleanComparator(new BooleanComparisonByEqualityPolicy());
if (CompareBooleans(a, b) == true) {
     System.Out.PrintLn("Sames!!!");
}

...

But now that I've written this, it's C#, so it's missing dependency injection.

[–] magic_lobster_party@fedia.io 6 points 2 weeks ago

I can imagine Uncle Bob be proud of this Clean Code (TM)