# GetHashCode()

> Returns a hash code of this string.

## Definition

* **Type:** Method
* **Namespace:** [Unity.Collections](/engine/6000.7/script-reference/unity/collections.md)
* **Assembly:** UnityEngine.ManagedKernelModule

```csharp
public override int GetHashCode()
```

### Returns

| Type                                                       | Description                 |
| ---------------------------------------------------------- | --------------------------- |
| [int](https://learn.microsoft.com/dotnet/api/system.int32) | A hash code of this string. |

### Remarks

The hash code is an integer that is always the same for two equal strings but (very likely) different for two unequal strings.
