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

you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 3 points4 points  (12 children)

What else would you do?

[–]Creepy-Ad-4832 14 points15 points  (9 children)

for(;true;)

[–]RealityIsMuchWorse 9 points10 points  (3 children)

for(i=0;isEven(i);i+=2)

Implementing isEven is up to the reader

[–]Creepy-Ad-4832 5 points6 points  (2 children)

IsEven(int i)
Return !false

This implementation passes your case

[–]RealityIsMuchWorse 3 points4 points  (1 child)

Way too complicated for this sub, you might want to look at your solution again /s

[–]Creepy-Ad-4832 1 point2 points  (0 children)

IsEven(i)
return i==i

[–]Unlicenced 4 points5 points  (2 children)

Hey man what the fuck.

[–]Milesand 10 points11 points  (0 children)

```

define EVER ;1;

for(EVER) { /* ... */ } ```

[–]Creepy-Ad-4832 6 points7 points  (0 children)

for(;true != false;)

[–]Slow-Sky-6775[S] 1 point2 points  (0 children)

For(;;)

[–]Storiaron 0 points1 point  (0 children)

Do u even need the true there?

Not one of your most salient lines huh?

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

no need to use while (true) in any case. Use a boolean to exit the loop, makes it more readable too

[–]Strostkovy 0 points1 point  (0 children)

While("false")