hash funciton added