pre-allocate slice for k hash values rather than allocate each time for add/check, based on @bradfitz's suggestion