Tuesday, Oh Dear Tuesday. Today I was able to learn the ways of Hash functions. They are actually quite impressive and might be used when I need to store big sets.
For those who don’t know and actually care, Hashes are used frequently when you need to store tons of information. Lets say you have n elements and n is quite large. In order to find an item in a list (lets assume its unsorted), it takes O(n) time steps (worst case scenario). Harsh! With a Hash Table though, you use a hash function to find the step so it takes O(1 + N/B) time steps (where B is the size of the hash). Obviously, this is quite faster than a regular list. If done properly, the search will be in constant time. Killer! If N approaches B though, the search gets slower. The best case is when N is about 50% of B. You developers should check it out if you haven’t already.

In other news, David once enlightened me by explaining that SKU stands for Stock Keeping Unit. WTF? Anyways, thats not the point. The point is, Google is now using 2D barcodes in newspaper ads. You can take a picture of the barcode with your cell phone and will be redirected (via special software) to a special page online with information on the product/event you requested. Nice right? Well sure, if you feel like going to download software for your phone. That is, if you’re phone’s supported. I imagine they are looking forward to when Android hits the big time. I’m sure this photo barcode software will come with the Google Cell Suite. Novel approach, even though Joel says its been done before. I can’t wait to see if people actually use it. [From Joel, via Techmeme]
More Info From Google on the ads, here.