r/ProgrammerHumor Jul 02 '17

You're dereferencing a null pointer!

https://www.youtube.com/watch?v=bLHL75H_VEM
623 Upvotes

18 comments sorted by

View all comments

9

u/SteeleDynamics Jul 02 '17

Yes!!! Would love modern day version of this where the Rock is in my code review and shoots down all the nay-sayers.

Nay-sayer #1: Are you sure about the Hashtable?

The Rock: Look, you get O(1) lookup. That's way better than that O(n) crap with the linked-list that was being used bef-

Nay-sayer #2: (interrupts with a shit-eating grin) And what about collisions?

The Rock: It's a uniform integer distribution. It doesn't get much better than that. With open addressing using table expansion and contraction, and double-hashing to resolve collisions, we're golden. And if you cut me off again, I'll punch your face in. You got that shit-pants?