use andand instead of long way to check for deep hash values