Work in progress: 181,232 of 181,233 sites checked so far, more every week · updated 2 Nov 2026Missing a blog? Tell us

Top all-time · #3546

L

Laurent Luce

Personal blog · laurentluce.comprogrammingsystems

Laurent Luce's personal blog at laurentluce.com covers programming and systems. Since 2011, 22 different Hacker News readers have linked it 24 times, most often “Python's Dictionary Implementation”. The last post was in 2020, but the archive is still widely read.

Visit the blog
24mentions?
22HN people?
2011–2022first – last linked?
Links on Hacker News per year · peak 5 in 2011

Too few sampled comments (8) to say how often HN recommends it.?

Why HN links it

HN readers link Laurent Luce's posts on CPython internals, such as integer objects, the list implementation, PyObject and the dictionary implementation, as references for how Python works under the hood.

Summarised by Claude from a sample of 8 HN comments that link here. Each comment is marked recommending, critical or neutral (citing without judging); how this works.

Most-linked posts?

  1. Python's Dictionary Implementation
    4 people · 4 mentions · first linked 2013-04-15
  2. Twitter sentiment analysis using Python and NLTK
    3 people · 3 mentions · first linked 2012-01-05
  3. Solving mazes using Python: Simple recursivity and A* search
    2 people · 2 mentions · first linked 2011-03-11
  4. Python Dictionary Implementation
    2 people · 2 mentions · first linked 2022-04-02

What Hacker News says?

  1. These kinds of diagrams are OK for the most basic introduction to data structures, but they're not much help when it comes to creating an efficient implementation. Learning about data structure implementation without using a relatively low-level language that allows pointers seems to be a recipe for confusion. Hence, one is probably always better off using the built-ins or libraries for any data structure in a highe…

    Comment linking /posts/python-dictionary-implementation/

    on “Data Structures Sketches”
  2. Submitted Twitter sentiment analysis using Python and NLTK as a story · 79 points

    HN discussion
  3. So likely thinking of it in terms of checking a tree based on characters instead of hashes of full words. Which is more viable would likely depend on what kind of memory constraints and dictionary size was being considered. Also very implementation dependent, what's the size of the hashes generated? Edit: curiosity got me looking at this for Python, with an answer of "it depends, and both have correct aspects" based…

    Comment linking /posts/python-dictionary-implementation/

    on “How to conduct a good programming interview”
  4. Submitted Python Locks, RLocks, Semaphores, Conditions, Events and Queues as a story · 33 points

    HN discussion
  5. Python statically allocates small integers (-5 to 256), so you're not actually creating a new object unless you're creating one outside that range. http://www.laurentluce.com/posts/python-integer-objects-impl...

    Comment linking /posts/python-integer-objects-implementation/

    on “Why Python is Slow: Looking Under the Hood”
  6. Submitted Solving mazes using Python: Simple recursivity and A* search as a story · 14 points

    HN discussion
  7. Here is blog post about python list implementation, one of 2 main data structures used internally: http://www.laurentluce.com/posts/python-list-implementation/

    Comment linking /posts/python-list-implementation/

    on “Python Internals: PyObject”
  8. Submitted Python’s dictionary implementation as a story · 8 points

    HN discussion
  9. Raw source: http://svn.python.org/view/%2acheckout%2a/python/tags/r266/O... Walkthrough of the implementation: http://www.laurentluce.com/posts/python-dictionary-implement...

    Comment linking /posts/python-dictionary-implementation/

    on “Read your Standard Libraries”
  10. Submitted Twitter sentiment analysis using Python and NLTK (2012) as a story · 3 points

    HN discussion
  11. My gut-ballpark was going to be around an order of magnitude, not two. Here's are two naive comparisons (granted, from the late aughts and not a direct comparison but a more general one) that show ~7-8x[0,1]. The overhead of PyStringObject is not trivial[2] (though the implementation details likely have changed between Py2.x and Python 3). For things like building accumulators a set of data/log parsing rather than d…

    Comment linking /posts/python-string-objects-implementation/

    on “The 2016 Top Programming Languages”
  12. Submitted Twitter sentiment analysis using Python and NLTK as a story · 3 points

    HN discussion
  13. Since there isn't any traversal when looking up an element n, I guess the best "short hand" would be to call it an array - it's an array of pointers to objects on the heap. https://www.laurentluce.com/posts/python-list-implementation... As for collections within collections, python allows for that in "lists" (arrays) and "dictionaries" (maps).

    Comment linking /posts/python-list-implementation/

    on “MISC: A homoiconic language based on maps”
  14. Submitted Python’s list implementation as a story · 3 points

    HN discussion
  15. It's puzzling that "x is 17" should work but then "1000 + 1 is 1001" doesn't. The reason is that Python pre-allocates 262 numbers at initialization (-5 to 256) and the allocation uses a different method/structure for bigger numbers. >>> x = 256 >>> x is 256 True >>> id(x) 94900419138400 >>> id(256) 94900419138400 >>> x = 257 >>> x is 257 False >>> id(x) 94900419504344 >>> id(257) 94900419504368 Reference: https://ww…

    Comment linking /posts/python-integer-objects-implementation/

    on “Python’s misleading readability”
  16. Submitted Python Dictionary Implementation as a story · 2 points

    HN discussion
  17. Submitted Python String Objects Implementation as a story · 2 points

    HN discussion
  18. Submitted Python's Dictionary Implementation as a story · 2 points

    HN discussion
  19. Submitted Solving mazes using Python: Simple recursivity and A* search as a story · 2 points

    HN discussion
  20. Submitted Create a Debian package for your Django application (2010) as a story · 1 points

    HN discussion
  21. Submitted Python Dictionary Internal Implementation as a story · 1 points

    HN discussion
  22. Submitted Python and cryptography with pycrypto as a story · 1 points

    HN discussion
  23. Submitted Geo data of the Massachusetts elementary school districts using Python as a story · 1 points

    HN discussion
  24. Submitted Python, Twitter statistics and the 2012 French presidential election as a story · 1 points

    HN discussion

Search all of HN for laurentluce.com

Linked by the same people?