Menu
rm -rf /: The factory reset button for your computer.
Home
Hot
Random
Search
Browse
AI
AWS
Agile
Algorithms
Android
Apple
Azure
Backend
Bash
C++
Cloud
All Categories
HTTP 418: I'm a teapot
The server identifies as a teapot now and is on a tea break, brb
HTTP 418: I'm a teapot
The server identifies as a teapot now and is on a tea break, brb
Rock-paper-scissors Memes
Posts tagged with Rock-paper-scissors
13 Year Old Me Really Liked Inefficient Code
Python
Programming
Algorithms
7 hours ago
1.6M views
0 shares
Someone really said "what if I manually hardcoded every single possible outcome in rock-paper-scissors instead of using, you know, basic logic?" Six separate if-statements checking every combination like they're getting paid per line of code. Rock beats scissors? Check. Rock ties with rock? Check. Rock loses to paper? Check. Now repeat for scissors... The beautiful part is that young programmers genuinely think more code = better code. Why write a simple win/loss comparison function when you can create a 40-line monstrosity that does the exact same thing? It's like using a sledgehammer to crack a walnut, except the sledgehammer is made of spaghetti code and the walnut is basic game logic. Fun fact: This could be reduced to like 5 lines with a dictionary/hashmap or even simpler with modulo arithmetic. But where's the fun in efficiency when you can manually type out every permutation like a human truth table?
Today's picks
Funny Programmer Coffee Gift for Coders T-Shirt Small
Affiliate
$17.99
Well
Programming
91.5K views
4 years ago
Irn Hatern This
Programming
96.0K views
4 years ago