The Sophistication Ladder of Conditional Statements
Description
This is a four-panel, vertical meme format, similar to the 'Expanding Brain' or 'Tuxedo Winnie the Pooh' memes, which ranks different ways of writing an 'else if' conditional statement. The first two panels feature a crudely drawn, tense-looking Winnie the Pooh, representing lower sophistication. Next to these are the words 'Elsif' and 'elif' respectively. The third panel shows a standard, calm-looking Winnie the Pooh next to the more common 'else if'. The final panel breaks the pattern entirely, displaying a simple, light-blue cartoon character with a mustache clenching its fist in front of a Union Jack flag. Next to this is the word 'otherwise'. The humor is derived from the escalation of programming language syntax from common variants ('elif' in Python, 'elsif' in Ruby) to the standard C-family 'else if', and finally to the absurdly formal and British-themed 'otherwise', which is not a standard keyword in most languages but perfectly captures a sense of over-the-top, quirky formality
Comments
35Comment deleted
Some developers use 'elif' for conciseness. Others prefer 'else if' for clarity. I, however, use 'otherwise', and my IDE is configured to only compile after it has queued up a formal complaint to the compiler's manager
The real portability layer isn’t POSIX - it’s a regex that translates every codebase’s preferred spelling of ‘else-if’ before the diff reviewer has an aneurysm
After 20 years of writing conditionals, you realize the real branching nightmare isn't elsif vs elif - it's explaining to the junior why your 'elegant' pattern matching solution with guards and monadic transformations takes 3x longer to debug than a simple switch statement
After 20 years in the industry, you realize the real sophistication isn't in choosing 'otherwise' over 'elsif' - it's in avoiding nested conditionals altogether by refactoring into a strategy pattern, only to have a junior dev rewrite it back to if-else chains because 'it's more readable.'
If the team is debating elif vs else if, the senior fix is a dispatch table or pattern matching - otherwise you’ve just built a 200‑line ladder
Polyglot repos prove the hardest cross-platform issue isn’t containers - it’s remembering whether the branch keyword is elif (Python), elseif (PHP), elsif (Ruby/Perl), else if (C/JS), or, if you’re in Spark, the aristocratic ‘otherwise’
15+ YoE truth: They all desugar to jumps, but 'otherwise' pairs best with a spot of tea during the perf regression
if ! Comment deleted
haskell moment Comment deleted
unless Comment deleted
is there a new lang called pringles? Comment deleted
elif is stupid. but ending an if block with fi is beyond moronic Comment deleted
bash : Comment deleted
Well, Bourne really liked Algol. But in Algol that stuff actually kinda works and is consistent. Comment deleted
please use English in this chat Comment deleted
ifn't Comment deleted
more like unless Comment deleted
Duded you just reversed the whole lookup Comment deleted
if(){} or(){} Comment deleted
this thing got more attention than I expected let's inplement it somewhere Comment deleted
💀💀😂😂😂 Comment deleted
nested when 🤬 Comment deleted
Elseways 🤴 Comment deleted
nextguess Comment deleted
oddchance Comment deleted
Apparently Comment deleted
Perchance 🇬🇧 Comment deleted
But otherwise=else🤔 Comment deleted
Doesn’t need to be Comment deleted
Semantically it is tho. And in no way otherwise=else if. if a==1 ... otherwise a==2 ... just doesn't work. Comment deleted
elfish Comment deleted
we also need block in any case Comment deleted
But still Comment deleted
in another case Comment deleted
ow Comment deleted