As a sheer programmer here on S/O, I believe funny comments should be kept indefinitely, unless they insult a specific group of people like Bill Woodger's comment above: "You still code in Javascript! LOL!"
is not acceptable because it degrades a huge crowd of programmers. It would also be insulting to degrade a small crowd (what one may think is impossible to find on the Internet: such as the Amish! Because, because someone on here may have an Amish family) or a "dead" programming language, because certain companies still rely on old languages! (Spectrum Health + COBOL).
I believe the occasional funny comment is actually key to a programmer's productivity and his general well-being. Because during those large projects where you haven't left the computer for 5 hours straight trying to debug a problem, most have considered quitting their job, or swearing at their boss, or coming on here and degrading new users on their completely valid questions. Joke comments canactually help a sleepless programmers' mind stay open-minded: to consider all the possibilities, including those easy ones such as "duh, this whole time I forgot to put that permission in the Android manifest!" They provide a comic relief that keeps a coder's priorities intact, like "you know what, I've spent a lot of time on this method, I should go try another method." I can't tell you how many times a joke comments has brought me back to my senses while programming, and I thank S/O for that.
TL;DR Keep funny comments unless they degrade a group of people.