calculating Hashcode directly