this post was submitted on 29 Aug 2023
14 points (85.0% liked)

Programmer Humor

31326 readers
18 users here now

Post funny things about programming here! (Or just rant about your favourite programming language.)

Rules:

founded 4 years ago
MODERATORS
 
top 10 comments
sorted by: hot top controversial new old
[–] [email protected] 4 points 10 months ago

Undefined property : lenght

[–] [email protected] 2 points 10 months ago

Syntax error: ? is not a valid operator

[–] [email protected] 2 points 10 months ago (1 children)

for(int i = 1; i > 0; i++)

[–] [email protected] 1 points 10 months ago* (last edited 10 months ago) (1 children)

-8 bytes

for (int i=1;;i++)

[–] [email protected] 1 points 10 months ago (1 children)

Not quite the same, there's a subtle but significant difference

[–] [email protected] 1 points 10 months ago (1 children)
[–] [email protected] 1 points 10 months ago

What happens on the next iteration when i = 2,147,483,647 for each of our loops?

[–] [email protected] 1 points 10 months ago (1 children)
[–] [email protected] 1 points 10 months ago (1 children)
[–] [email protected] 1 points 10 months ago

Speak for yourself