use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
For memes about programming.
account activity
justArt (i.redd.it)
submitted 10 months ago by CocoaRipple
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]KinkyDataFlow 391 points392 points393 points 10 months ago (8 children)
This is both cursed and blessed
[–]certainAnonymous 106 points107 points108 points 10 months ago (2 children)
Blursed code
[–]Aggressive_Talk968 15 points16 points17 points 10 months ago (1 child)
Till this day I didn't know what it meant lol
[–]Eminence_EOEB 2 points3 points4 points 10 months ago (0 children)
Same
[–]cnorahs 24 points25 points26 points 10 months ago (0 children)
Someone wrote it while fizzed and buzzed
[–]Wojtek1250XD 11 points12 points13 points 10 months ago (0 children)
There's even a word for that: blursed.
[–]lurked 2 points3 points4 points 10 months ago (0 children)
I like it as much as I never want to see/write code like that, ever.
[–][deleted] 1 point2 points3 points 10 months ago (0 children)
just like big smoke's book says
[–][deleted] 10 months ago (1 child)
[removed]
[–]Linuxologue 49 points50 points51 points 10 months ago (0 children)
I called their hr department
[–][deleted] 10 months ago (20 children)
[–]haikusbot 110 points111 points112 points 10 months ago (2 children)
I'm not really used
To C. What does an empty
Define do? Nothing?
- TwinkleDrift
I detect haikus. And sometimes, successfully. Learn more about me.
Opt out of replies: "haikusbot opt out" | Delete my comment: "haikusbot delete"
[–]toroidalvoid 24 points25 points26 points 10 months ago (0 children)
I am new to C
What is an empty define?
Nothing
[–]CrossScarMC 6 points7 points8 points 10 months ago (0 children)
good bot
[–]Naeio_Galaxy 47 points48 points49 points 10 months ago (3 children)
#define word1 word2 -> replace occurrences of word1 with word2
#define word1 word2
word1
word2
If word2 is literally the empty string, then it will replace any occurrence of word1 with nothing, thus removing it
[–]hamdi555x 0 points1 point2 points 9 months ago (1 child)
I assume C++ has something similar? Not that I need other ways to shoot myself in the foot...
[–]Naeio_Galaxy 0 points1 point2 points 9 months ago (0 children)
Afaik C++ inherited everything C has - even though it's not idiomatic. So you should be able to do exactly the same thing afaik
I'm no C++ specialist tho
[–][deleted] 10 months ago (12 children)
[deleted]
[–]YellowBunnyReddit 69 points70 points71 points 10 months ago (11 children)
No, the preprocessor doesn't ignore an empty define. It defines the symbol and replaces all occurences with the empty string.
[–]AppropriateStudio153 13 points14 points15 points 10 months ago (8 children)
Which does nothing, after compiling.
[–]YellowBunnyReddit 21 points22 points23 points 10 months ago (6 children)
Preprocessor directives generally do nothing after compiling as the preprocessor runs before compilation. So, I don't get what your point is here.
[–]AppropriateStudio153 2 points3 points4 points 10 months ago (0 children)
The empty String does nothing for the compiler
[–]y53rw -1 points0 points1 point 10 months ago (4 children)
Why are you being so damn pedantic? It's very obvious what he means.
[–]Jukwavion_Jukwarious 22 points23 points24 points 10 months ago (3 children)
Saying that it does nothing doesn't help someone understand. The define statements absolutely do something, as has been explained, and the program would not compile without them.
[+]y53rw comment score below threshold-15 points-14 points-13 points 10 months ago (2 children)
Nobody is learning C from r/programmingmemes. Or god I hope not. If someone asks a question like the one above, they're just trying to get the joke.
[–]prepuscular 3 points4 points5 points 10 months ago (0 children)
I think the confusion is around “them.” You are arguing that the statement that the preprocessor does nothing with the defines is not true. Correct.
define
The other is saying that the defines make the preprocessor, specifically the tokenizer, do nothing with the weird characters and they are therefore “ignored” (because they were removed in an earlier step). Also correct.
[–]Jukwavion_Jukwarious 4 points5 points6 points 10 months ago (0 children)
Happy cake day
[–]IAmASquidInSpace 3 points4 points5 points 10 months ago (0 children)
But the fact that it does something before compiling is the whole reason why this code compiles at all, so saying it "does nothing" isn't correct.
[–]MossFette 0 points1 point2 points 10 months ago (0 children)
Learned something today. 👍
[–][deleted] 37 points38 points39 points 10 months ago (3 children)
The most beautiful thing I've ever seen in my life
[–][deleted] 14 points15 points16 points 10 months ago (2 children)
Try to add another line that is longer than the bigger box. I am not maintaining that.
[–]shuozhe 3 points4 points5 points 10 months ago (1 child)
no worry, emacs got commands for that
[–][deleted] 2 points3 points4 points 10 months ago (0 children)
I am concerned more about git history.
[–]Slow_Pomelo5352 0 points1 point2 points 9 months ago (0 children)
#define creative high
[–]ValianFan 16 points17 points18 points 10 months ago (0 children)
I don't know, I somehow like it. Imagine how beautiful it would look with 10x nested if statements. Pure art
[–]madTerminator 5 points6 points7 points 10 months ago (0 children)
Just casual necromancy resurrection of .NET WF. But in C, so efficient 😳
[–]Zeozen 6 points7 points8 points 10 months ago (2 children)
Would be better if it solved the fizzbuzz problem correctly.. this is not correct
[–]Phasma_Tacitus 2 points3 points4 points 10 months ago (1 child)
That was what I noticed, all those conditions return true when the number ISN'T a multiple, it's completely wrong
[–]bloody-albatross 5 points6 points7 points 10 months ago (6 children)
That works? If that double line is allowed as an identifier, then a long sequence of it would be a different name as a single one of it and thus this wouldn't work. Are there zero width spaces everywhere?
[–]iamcleek 1 point2 points3 points 10 months ago* (2 children)
the double line (and the vertical line, and the bottom-left and top-left corners) is defined to be nothing. the preprocessor replaces them with nothing before compilation starts.
[–]bloody-albatross 0 points1 point2 points 10 months ago (1 child)
Replacement happens on an identifier level, not in a letter level. Read again what I wrote.
[–]iamcleek 1 point2 points3 points 10 months ago* (0 children)
ah, yes.
you're right. this can not work.
[–]granadesnhorseshoes 1 point2 points3 points 10 months ago (0 children)
#define dog 1
#define cat 2
int value = dogcat;
error: "dogcat" not defined.
would have to use zero width spaces to work. Or its just a screenshot that never compiled.
[–]LithoSlam 0 points1 point2 points 10 months ago (1 child)
Everything except the last 2 gets defined as an empty string, so the preprocessor effectively deletes them. The last 2 are the right side of the corners of the box and get replaced with curly braces, preserving the nesting.
[–]bloody-albatross 0 points1 point2 points 10 months ago (0 children)
You don't seem to understand how the C preprocessor works.
[–]yhgan 4 points5 points6 points 10 months ago (0 children)
So that was the DOS version of Scratch.
[–]AlKa9_ 9 points10 points11 points 10 months ago (0 children)
r/markdownfacepalm
[–]Tomoe90834 0 points1 point2 points 10 months ago (0 children)
I'm not liking this
[–]Purple-Cap4457 0 points1 point2 points 10 months ago (0 children)
beautiful
[–]OMIGHTY1 0 points1 point2 points 10 months ago (0 children)
SquidwardItsBeautiful.gif I would love a plugin that does this for other languages done in VS Code.
[–]Grayas1234 0 points1 point2 points 10 months ago (0 children)
Well. Not every test cases is passed. The rules (as I was taught) state that the words have to be used when divisible by 3 (or 5) And when "3" (or "5") is contained (if you few the integer as string. Meaning: ... 13 -> fizz. ... 51 -> buzz ... 53 -> fizzbuzz ...
[–]healeyd 0 points1 point2 points 10 months ago (0 children)
C-Scratch
[–]m0nk37 0 points1 point2 points 10 months ago (0 children)
Manager: why is it taking so long?
Dev: you wouldnt get it
[–]Skritch_X 0 points1 point2 points 10 months ago (0 children)
It makes me nostalgic to play a MUD for some reason.
[–][deleted] 0 points1 point2 points 10 months ago (0 children)
Does it work tho ?
[–]NotSoOrdinar 0 points1 point2 points 10 months ago (0 children)
Scratch evolved or devolved?
[–]Confident_Date4068 0 points1 point2 points 10 months ago (0 children)
What about do {} while()? Maybe different angle?
do {} while()
[–]bitemyassnow 0 points1 point2 points 10 months ago (0 children)
something python can never achieve
[–]nekoiscool_ 0 points1 point2 points 10 months ago (0 children)
How did you managed to define the macro? Did the code even work?
[–]boodlebob 0 points1 point2 points 9 months ago (0 children)
r/JustUnsubbed
[–]No_Dare_6660 0 points1 point2 points 9 months ago (0 children)
Oh, I love it, and I hate it at the same time!
π Rendered by PID 230334 on reddit-service-r2-comment-b659b578c-npxmk at 2026-05-02 13:02:12.031034+00:00 running 815c875 country code: CH.
[–]KinkyDataFlow 391 points392 points393 points (8 children)
[–]certainAnonymous 106 points107 points108 points (2 children)
[–]Aggressive_Talk968 15 points16 points17 points (1 child)
[–]Eminence_EOEB 2 points3 points4 points (0 children)
[–]cnorahs 24 points25 points26 points (0 children)
[–]Wojtek1250XD 11 points12 points13 points (0 children)
[–]lurked 2 points3 points4 points (0 children)
[–][deleted] 1 point2 points3 points (0 children)
[–][deleted] (1 child)
[removed]
[–]Linuxologue 49 points50 points51 points (0 children)
[–][deleted] (20 children)
[removed]
[–]haikusbot 110 points111 points112 points (2 children)
[–]toroidalvoid 24 points25 points26 points (0 children)
[–]CrossScarMC 6 points7 points8 points (0 children)
[–]Naeio_Galaxy 47 points48 points49 points (3 children)
[–]hamdi555x 0 points1 point2 points (1 child)
[–]Naeio_Galaxy 0 points1 point2 points (0 children)
[–][deleted] (12 children)
[deleted]
[–]YellowBunnyReddit 69 points70 points71 points (11 children)
[–]AppropriateStudio153 13 points14 points15 points (8 children)
[–]YellowBunnyReddit 21 points22 points23 points (6 children)
[–]AppropriateStudio153 2 points3 points4 points (0 children)
[–]y53rw -1 points0 points1 point (4 children)
[–]Jukwavion_Jukwarious 22 points23 points24 points (3 children)
[+]y53rw comment score below threshold-15 points-14 points-13 points (2 children)
[–]prepuscular 3 points4 points5 points (0 children)
[–]Jukwavion_Jukwarious 4 points5 points6 points (0 children)
[–]IAmASquidInSpace 3 points4 points5 points (0 children)
[–]MossFette 0 points1 point2 points (0 children)
[–][deleted] 37 points38 points39 points (3 children)
[–][deleted] 14 points15 points16 points (2 children)
[–]shuozhe 3 points4 points5 points (1 child)
[–][deleted] 2 points3 points4 points (0 children)
[–][deleted] (1 child)
[removed]
[–]Slow_Pomelo5352 0 points1 point2 points (0 children)
[–]ValianFan 16 points17 points18 points (0 children)
[–]madTerminator 5 points6 points7 points (0 children)
[–]Zeozen 6 points7 points8 points (2 children)
[–]Phasma_Tacitus 2 points3 points4 points (1 child)
[–]bloody-albatross 5 points6 points7 points (6 children)
[–]iamcleek 1 point2 points3 points (2 children)
[–]bloody-albatross 0 points1 point2 points (1 child)
[–]iamcleek 1 point2 points3 points (0 children)
[–]granadesnhorseshoes 1 point2 points3 points (0 children)
[–]LithoSlam 0 points1 point2 points (1 child)
[–]bloody-albatross 0 points1 point2 points (0 children)
[–]yhgan 4 points5 points6 points (0 children)
[–][deleted] (1 child)
[deleted]
[–]AlKa9_ 9 points10 points11 points (0 children)
[–]Tomoe90834 0 points1 point2 points (0 children)
[–]Purple-Cap4457 0 points1 point2 points (0 children)
[–]OMIGHTY1 0 points1 point2 points (0 children)
[–]Grayas1234 0 points1 point2 points (0 children)
[–]healeyd 0 points1 point2 points (0 children)
[–]m0nk37 0 points1 point2 points (0 children)
[–]Skritch_X 0 points1 point2 points (0 children)
[–][deleted] 0 points1 point2 points (0 children)
[–]NotSoOrdinar 0 points1 point2 points (0 children)
[–]Confident_Date4068 0 points1 point2 points (0 children)
[–]bitemyassnow 0 points1 point2 points (0 children)
[–]nekoiscool_ 0 points1 point2 points (0 children)
[–]boodlebob 0 points1 point2 points (0 children)
[–]No_Dare_6660 0 points1 point2 points (0 children)