結果 : how to write hash function in python