9: Added better hash function