Basic hash function done