@Shervan360 , Welcome to Microsoft Q&A, based on your description, you want to know how the GetHashCode work in IEqualityComparer.
The GetHashCode method is used to generate an address where the object is stored. So, a dictionary doesn't have to search for it. It just computes the Hash code and jumps to that location. The Equals method is a better test of equality but cannot be used to map an object into an address space.
The answer has a good example and enough explanation for it and you could have a look.
Best Regards,
Jack
If the answer is the right solution, please click "Accept Answer" and upvote it.If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.