# Structs as keys of a HashMap

* struct
* derive
* Debug
* Hash
* Eq
* PartialEq

* We can also use structs as a keys in a HashMap, but for that we need to add a few traits.

{% embed include file="src/examples/hashes/structs-as-keys/src/main.rs" %}

{% embed include file="src/examples/hashes/structs-as-keys/out.out" %}


