returneksibir/yakala — comment on commit d11a69bf12a4cce94f5b7110ca7c69490f2d0390
File:  line 0
By rimbi:

On Mon, Oct 17, 2011 at 3:16 PM, Sinan Nalkaya <
reply@reply.github.com>wrote:

> 1 - hash function has to generate unique value per string. if you are
> saying that i will use strings and i am pretty sure that they will not the
> same size and their 1st, 7th and 11th numbers will not be same! i then say
> thats ok, but i would not call that a hash function.
>

[Cem] That's not a correct definition. The only requirement for (at least a
trivial) hash function is being deterministic. That is to say, given an
input, it always produces the same result.
hashCode method of String class returns an integer value. According to your
definition, then, we would be allowed to enter only MAX_INT different inputs
to the hashCode method. Right?

besides that i remember i was talking about saving hash values of the links,
> what changed your mind? you were against that idea.
>
[Cem] Sorry, I remember neither the discussion nor my arguments. By the
way, in this proposal there is no such thing as saving hash values.

3 - i will look the code more carefully.
> 4 - letme tell you some criterias;
> if you can use this as ref db like i did, you may use it in couple of
> places, if you provide abstraction, you can change algorithm of saving
> method, like using hash or saving some other container other than set for
> example.
>

[Cem] Ok, let's assume that you had a better design. That's nice. The
problem is that you haven't come up with a compact solution specific to this
problem yet (have you?). We have had to fix it and here is a quick solution
that seems to work.

>
> --
> Reply to this email directly or view it on GitHub:
>
> https://github.com/returneksibir/yakala/commit/d11a69bf12a4cce94f5b7110ca7c69490f2d0390#commitcomment-655693
>