Live data from Hacker News

Ask HN: Anyone know any funny programming jokes?

news.ycombinator.com

341–350 of 905 posts

Re: Ask HN: Anyone know any funny programming jokes?

#341
post #295

Earlier quoted context omitted.

An infinite number of mathematicians walk into a bar, where a beer costs 3$. The first mathematician orders a beer. The second mathematician orders two beers. The third mathematician orders three beers. "Oh, I see where this is going" says the bartender and pays a quarter to the first mathematician. "This should cover your check, then."

Is this an antijoke or did I just need to know where it's going, like the bartender? Maybe the bartender is confused?

The joke is that the Ramanujan sum of 1 + 2 + 3 + 4 + ... is equal to -1/12, so the check should be $3 * -1/12 = minus one quarter. [0]

[0]: https://en.wikipedia.org/wiki/1_%2B_2_%2B_3_%2B_4_%2B_%E2%8B...

Re: Ask HN: Anyone know any funny programming jokes?

#342
post #295

Earlier quoted context omitted.

An infinite number of mathematicians walk into a bar, where a beer costs 3$. The first mathematician orders a beer. The second mathematician orders two beers. The third mathematician orders three beers. "Oh, I see where this is going" says the bartender and pays a quarter to the first mathematician. "This should cover your check, then."

Can you explain?

It's referencing a theorem from string theory, as discussed in this Numberphile video: https://www.youtube.com/watch?v=w-I6XTVZXww

The catch is that this isn't valid in what we consider standard mathematics, and you can find many discussions of this online, but this one is fairly short and straightforward: http://curiouscheetah.com/BlogMath/infinity-and-string-theor...

Re: Ask HN: Anyone know any funny programming jokes?

#344

An infinite number of mathematicians walk into a bar. The first mathematician orders a beer. The second orders half a beer. "I don't serve half-beers" the bartender replies. "Excuse me?" Asks mathematician #2. "What kind of bar serves half-beers?" The bartender remarks. "That's ridiculous." "Oh c'mon" says mathematician #1 "do you know how hard it is to collect an infinite number of us? Just play along". "There are v…

So the programmers joke here is the silent nod to jamie zawinski, as a maths savvy guy who is bartending?

https://www.jwz.org/about.html

Re: Ask HN: Anyone know any funny programming jokes?

#345

Earlier quoted context omitted.

If you mean you're not a programmer, rad, good compliment. If you mean QA engineers aren't programmers... wtaf?

It's weird how some people admit they still test code by hand

It's very simple: you test things because we can't rely 100% on developers to create the right thing or to create it without any bugs. The same goes for automated test software. I've personally created unit tests that were failing for like 2 years but due to a bug still showed green in CI.

To go back to the joke: manual QA is infinitely more likely to find the exploding bathroom than a unit test would ;)

Automated testing is a fantastic tool, but manual QA is still very valuable.

Re: Ask HN: Anyone know any funny programming jokes?

#348

Earlier quoted context omitted.

Then he thought he'd use Java. Now he has a ProblemFactory.

This is funny because no one uses the factory pattern in other languages

You'd be surprised to see how many WhateverFactory classes there are in the current python project I'm working on... sigh.

Re: Ask HN: Anyone know any funny programming jokes?

#350
post #295

Earlier quoted context omitted.

An infinite number of mathematicians walk into a bar, where a beer costs 3$. The first mathematician orders a beer. The second mathematician orders two beers. The third mathematician orders three beers. "Oh, I see where this is going" says the bartender and pays a quarter to the first mathematician. "This should cover your check, then."

Can you explain?

1 + 2 + 3 + ... = -1/12 total beers

-1/12 beers * $3 / beer = -$0.25

negative -> pay them for taking the beer

The -1/12 result is pretty widely known, but not particularly true. It's called "analytic continuation." There's a nonrigorous proof that's accessible at a highschool level - see [here](https://en.wikipedia.org/wiki/1_%2B_2_%2B_3_%2B_4_%2B_%E2%8B...)

Delightfully, this comes up in string theory, in computing the dimensionality of spacetime.

Post reply on HN