---
title: "Discussion on \"Ten Threads, Ten Thousand Increments, and a Counter That Came Up Short\" | Hashnode"
description: "Discussion on \"Ten Threads, Ten Thousand Increments, and a Counter That Came Up Short\". Every concurrency tutorial has the same demo. Ten threads, each increments a shared counter 1,000 times, the answer should be 10,000, and without a lock it comes up short. I ran it. It came back 10,00"
url: "https://hashnode.com/posts/ten-threads-ten-thousand-increments-and-a-counter-that-came-up-short/6af55f6e4e46d0bbbcb78c6e"
---

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

Discussion

# [Ten Threads, Ten Thousand Increments, and a Counter That Came Up Short](https://aheadkit.hashnode.dev/ten-threads-ten-thousand-increments-and-a-counter-that-came-up-short?utm_source=hashnode&utm_medium=feed)

Every concurrency tutorial has the same demo. Ten threads, each increments a shared counter 1,000 times, the answer should be 10,000, and without a lock it comes up short. I ran it. It came back 10,00

6h ago · 5 min read · aheadkit.hashnode.dev  
Read the article

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

## Written by

[Abdus Salam](https://hashnode.com/@aheadkit)

@aheadkit

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

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
