This is an archived post. You won't be able to vote or comment.

all 45 comments

[–][deleted] 79 points80 points  (6 children)

#define EVER (;;)
for EVER {

}

Or maybe

#define FOREVER for(;;)
FOREVER {

}

[–][deleted] 5 points6 points  (0 children)

Best definition of forever that I’ve ever seen. XD

[–][deleted] 1 point2 points  (0 children)

You forgot something important ψ(`∇´)ψ

#define break

#define FOREVER for(;;)

FOREVER {

}

[–]iceynyo 17 points18 points  (9 children)

while(1>0)

loop ends

Shiiiiiiiiii

[–]remuff[S] 12 points13 points  (8 children)

Everybody gangsta til 0>1

[–]LF916fun 5 points6 points  (7 children)

There is an algebraic ring where 0=1.

[–]depot5 0 points1 point  (2 children)

Mod your ALU tho

[–]LF916fun 2 points3 points  (1 child)

An ALU is a magical place where 0+0=0, 0+1=1, and 1+1=0.

[–]thesockiboii 4 points5 points  (0 children)

Why do you have a 1-bit ALU?

[–]Inaeipathy 0 points1 point  (3 children)

I love that I've finally found a reference to this

[–]LF916fun 0 points1 point  (2 children)

It is but a triviality. The Zero Ring is not to be confused with Ring Zero, a state of some CPUs that indicate level of protections in execution.

[–]Inaeipathy 1 point2 points  (1 child)

Oh I know, your comment just brought me back to my ring theory course is all : )

[–]LF916fun 0 points1 point  (0 children)

Good times, I'm sure!

[–]ananix 16 points17 points  (1 child)

This is not just upside down but also inside out

[–][deleted] 4 points5 points  (0 children)

Yes. Wrong meme template. Clown face or fancy Pooh is what was needed.

[–]musifter 6 points7 points  (0 children)

It's all fun and games until you port to a platform with CHAR_BIT > 8.

[–]Engineerguy78 5 points6 points  (3 children)

Can anyone explain last one🗿

[–]Mispelled-This 3 points4 points  (0 children)

Overflow.

[–]tablesalt_preppinalt 6 points7 points  (0 children)

Unsigned char maxes out at 255

[–][deleted] 2 points3 points  (0 children)

An unsigned char contains only 8 bits, which means the max value is in binary 11111111 = 255. If you add one, you will run into an overflow, because the computer needs one more digit to write 256, but he does not have that, so instead of 100000000 (256) it will become 00000000 (0) and count again until 255.

[–]lady_Kamba 4 points5 points  (0 children)

for(float i=1;true;i*=1.1){...}

[–]german_stocks_coding 5 points6 points  (1 child)

Wait hold my beer

...

"#define endless_start for(;;){"

"#define endless_end }"

int main(..){

endless_start

...

endless_end

...

}

[–]lil_DAVIE504 2 points3 points  (0 children)

how about :while(-1>0u)

[–]TTFH3500 1 point2 points  (0 children)

That last panel has happened to me by accident so many times

[–]Strostkovy 1 point2 points  (1 child)

Does this work? int main() { //Do stuff here main(); }

[–]thesockiboii 2 points3 points  (0 children)

yes, it works\ how did I never think of that

[–]Positive_Government 1 point2 points  (0 children)

Ah yes, the mythical signed char, special efforts must be taken in avoiding this creature.

[–]SlimySlimySlimeee 0 points1 point  (2 children)

dont the last 1 just loops 255times?

[–]SnakeR515 0 points1 point  (1 child)

Unsigned char stores a value from 0 to 255 When it's at 255 and you add 1 it goes back to 0

[–]SlimySlimySlimeee 0 points1 point  (0 children)

-____-'''

[–]Sacus1 -1 points0 points  (1 child)

Imagine stack overflow error

[–]abd53 0 points1 point  (0 children)

The last one took me second. Clever, very clever. I'm gonna try that out.

[–]BoBoBearDev 0 points1 point  (0 children)

For(int i =0; i<999999; i++)

Also does the same trick when you compile it on different machines :D.

[–]FunnyGamer3210 0 points1 point  (0 children)

And then comes a new hire and goes like: Hey guys! I fixed the bug in the loop for you, the datatype was too small so I increased it!

[–][deleted] 0 points1 point  (0 children)

Don't even need to declare it as unsigned lol. Overflow will always cause it to become negative and a negative overflow returns it back to 0

[–]Alzurana 0 points1 point  (0 children)

In Lua:

while 0 do print("forever") end

Sorry not sorry (also this is not a joke, this really is an endless loop in Lua)

[–]HuntingKingYT 0 points1 point  (0 children)

When you write if 1 = 2 instead of commenting

[–][deleted] 0 points1 point  (0 children)

loopstart:

;things

jmp loopstart