Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

array_sum_of_1_2_3_4_5();

(Added in PHP 6)



the funny thing is, with proper abuse of __call you can almost get that to work: https://gist.github.com/kennethrapp/328b6bd1bda8a8f94092


That's not funny. Horrifying, maybe, but not funny.

Edit: Strike 'maybe'. I looked at it again and it's definitely horrifying. I saved it anyway, though; Halloween's only a few weeks off, and I think I shall print it out and stick it on the wall of my cube next to the PHP hammer and the "periodic" table of Perl 6 operators.


kudos. almost as cool as the cpp template hack to compute area based on part of the source code 'ascii art' size. (which I can't find anymore. googlefu--)


Made me laugh :)




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: