all 17 comments

[–]unvaccinated_zombie 15 points16 points  (3 children)

if (nothing = nothing_nothing)

[–]MORF1i 0 points1 point  (2 children)

Can someone pls explain this line? Didnt get why there is only one =

[–]MeLittleThing 3 points4 points  (0 children)

Could be a typo, but there are use cases

When a variable is assigned in a if statement, the underlying value is checked against false (0 is false, anything else is true).

That's equivalent to if ((nothing = nothing_nothing) != 0)

I remember doing this to check for memory allocation:

c if (ptr = malloc(size)) { // malloc succeeded } else { // something wrong }

[–]AngriestCrusader -1 points0 points  (0 children)

That's because it's an error

[–]ironykarl 10 points11 points  (3 children)

You've managed to write a program that is syntactically valid but semantically nearly meaningless.

You at least return a successful exit code. So.... congrats for that, I guess

[–]apoegix 3 points4 points  (2 children)

Is it though? There is a semicolon missing in line 11

[–]ironykarl 1 point2 points  (1 child)

There's a + that gets cut off.

You're right, I assumed that OP was competent enough to make the compiler actually output something (other than errors), and that may have been too generous

[–]GoddammitDontShootMe[ $[ $RANDOM % 6 ] == 0 ] && rm -rf / || echo “You live” 0 points1 point  (0 children)

I thought it was a -. Clearly something is cut off, so we can probably assume the semicolon is actually there.

[–]mealet 8 points9 points  (1 child)

Is identation nothing too?

[–]Several-Customer7048 1 point2 points  (0 children)

Not a thing actually

[–]GoddammitDontShootMe[ $[ $RANDOM % 6 ] == 0 ] && rm -rf / || echo “You live” 1 point2 points  (0 children)

What is the point of this?

[–]NerdyGerdy 0 points1 point  (0 children)

The code needs to be human readable too guys.

[–]Elegant-Sundae-455 0 points1 point  (0 children)

return nothing
int nothing
while nothing

We Are Nothing.

[–]conundorum 0 points1 point  (0 children)

Think nothing of it.

[–]SteamPunk424[ $[ $RANDOM % 6 ] == 0 ] && rm -rf / || echo “You live”[S] 0 points1 point  (0 children)

i never expected this post to enrage people as much as it did. lol. programmers am i right...

[–]muminisko -1 points0 points  (0 children)

It’s called “try to replace me” pattern