ProgrammerHumor

breakOperator

breakOperator
https://i.redd.it/ipahyhyb9sbf1.jpeg
Reddit

Discussion

riztazz
:cp:

This meme gets reposted so often, it feels recursive

1 day ago
Bright-Tear9755

Ikr I just saw it here

1 day ago
SupernovaGamezYT
:m:

(Me clicking the link, scrolling down, and clicking it again to make the joke continue)

23 hours ago
charliesname
:cs:

This meme gets reposted so often, it feels recursive

1 day ago
Octupus_Tea
:cp:

This meme gets reposted so often, it feels recursive

1 day ago
FjellaTheBirb

This meme gets reposted so often, it feels recursive

19 hours ago
zeocrash

While(true)

{

RepostMeme();

SleepDays(random.next());

}

1 day ago
Tuafew

Say that again 🤨

1 day ago
fiskfisk

break is not an operator. It doesn't operate on anything.

It'll usually be documented as a statement. 

If you're going to repost, it's time to clean up the meme. Refactor it a bit. Leave it nicer than you found it. Run the tests. 

1 day ago
alexanderpas
:p::py:

technically, break can be considered a nullary operator, as it operates on the current loop, by ending it, without accepting any arguments.

1 day ago
fiskfisk

I wouldn't consider it a nullary operator since it doesn't return a value either. You can argue that "it modifies PC so it's an operator on that register" - but that's a stretch in my view. 

22 hours ago
ridicalis

I didn't know we were allowed to fix stuff; I thought it was just technical debt that Dave was going to fix one of these days.

1 day ago
Surprise_Cross_Join

Endless loop != recursion…

1 day ago
Searbh

 A man walks into a bar and says "I'll have a joke a bout recursion please". The bartender says "Sure: A man walks into a bar and says "I'll have a joke a bout recursion please". The bartender says "Sure: A man walks into a bar and says "I'll have a joke a bout recursion please". The bartender says "Sure: A man walks into a bar and says "I'll have a joke a bout recursion please". The bartender says "Sure: ...

1 day ago
Ronin-s_Spirit
:js:

Technically a recursive function without a guard clause == while (true) even if recursive function without a guard clause !== while (true).

1 day ago
Saelora

depends on the language, ina. lot of languages a recursive function will crap out when the call stack maxes out while a while true will just keep going till killed.

1 day ago
knightress_oxhide

what language doesn't crap out when the memory runs out?

1 day ago
Saelora

none, but some of them have infinite loop protection.

1 day ago
Ronin-s_Spirit
:js:

That's why I said it's not exactly equal.

1 day ago
alexanderpas
:p::py:

If the language supports tail recursion optimisation, it won't crap out, since the next iteration is made only after the previous iteration has concluded.

1 day ago
ohdogwhatdone

Embedded devs: where's the joke?

1 day ago
SunshineSeattle

You know what I saw browsing some code for a dev board was this:

``` for(;;) {    // Stuff }

```

And I don't know how to feel about it.

1 day ago
Mast3r_waf1z

I've seen for(;;); before, accompanied by an interrupt

1 day ago
Mediocre-Advisor-728

Was it cube ide for stm32?

1 day ago
ohdogwhatdone

Not a big fan, I call it the depressed endless loop ;-;

1 day ago
SunshineSeattle

Accurate lol

1 day ago
Taletad

You’re confusing a recursive function without an exit clause, with an infinite loop

1 day ago
EsotericLife

Who needs a break? Use redefine true to == false, duh.

1 day ago
monsieurlouistri

Op did not write a line of code of his entire life, change my mind

1 day ago
_Alpha-Delta_
:py::cp::c::asm::bash::snoo_trollface:

Nah, just put a "go to" instruction.

Or use it with purpose to trap a microcontroller program after putting your contraption in a safety mode. 

1 day ago
MrHyd3_

This is reposted so often I fixed it

1 day ago
Giocri

I would have added a few More iterations but yeah much better

1 day ago
SuckMyAlpagoat

wait there is a end to the meme so he did write a break statement

1 day ago
Global-Tune5539

Maybe he used return?

23 hours ago
schewb

I feel like the meme would be super long if it was a while loop instead of recursing on itself and just be Padme saying her line over and over.

23 hours ago
batatatchugen

Standard practice for microcontrollers.

21 hours ago
JackNotOLantern

You can throw an exception or kill the thread/process instead

21 hours ago
jhill515
:c::cp::py::bash::m::snoo_trollface:

int main(int, char**) { while(true) { laughInMainLoop(); repostBullshit(); refreshDay(); }; }

19 hours ago
navetzz

Return

19 hours ago
Disciple153
:rust: :c: :cp: :cs: :py: :ts:

13 hours ago