this post was submitted on 12 Sep 2025
441 points (98.9% liked)

Programmer Humor

26328 readers
1565 users here now

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

founded 2 years ago
MODERATORS
 
you are viewing a single comment's thread
view the rest of the comments
[–] bobo@lemmy.ml 1 points 1 day ago

Good point, but you can do if === true... and else if === false...

But definitely better to throw an error instead of nan.