---
title: "Discussion on \"TypeError: unhashable type: 'list' in Python: 10 Causes and Fixes for Dict Keys, Sets, Counter and lru_cache (Tested Examples)\" | Hashnode"
description: "Discussion on \"TypeError: unhashable type: 'list' in Python: 10 Causes and Fixes for Dict Keys, Sets, Counter and lru_cache (Tested Examples)\". Python raises TypeError: unhashable type: 'list' when you use a list where Python needs a hashable value: as a dictionary key, as an element of a set, in an in check against a set or dict, or as an ar"
url: "https://hashnode.com/posts/python-typeerror-unhashable-type-list/6af298d1b6886c50c260b6fe"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [TypeError: unhashable type: 'list' in Python: 10 Causes and Fixes for Dict Keys, Sets, Counter and lru\_cache (Tested Examples)](https://mfaysaldev.hashnode.dev/python-typeerror-unhashable-type-list?utm_source=hashnode&utm_medium=feed)

Python raises TypeError: unhashable type: 'list' when you use a list where Python needs a hashable value: as a dictionary key, as an element of a set, in an in check against a set or dict, or as an ar

7h ago · 16 min read · mfaysaldev.hashnode.dev  
Read the article

-   [#python](https://hashnode.com/tag/python)
-   [#debugging](https://hashnode.com/tag/debugging)
-   [#beginners](https://hashnode.com/tag/beginners)

## Written by

[Mahir Faysal](https://hashnode.com/@mfaysaldev)

@mfaysaldev

  
[View profile](https://hashnode.com/@mfaysaldev)

Student web developer — PHP, JavaScript, Next.js

I write practical coding tutorials at https://mfaysal.com | Learning cybersecurity on TryHackMe: https://tryhackme.com/p/mfaysal.dev

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
