Posts about Python written by Chris Webb
Observer pattern in Python. Full code example in Python with detailed comments and explanation. Observer is a behavioral design pattern that allows some objects to notify other objects about changes in their state
[Python-Dev] Alternative implementation of string interning Oren Tirosh [email protected] Tue, 2 Jul 2002 20:55:07 +0300 Previous message: [Python-Dev] Alternative implementation of string interning Next message: [Python-Dev] Alternative implementation of string interning Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] On Tue, Jul 02, 2002 at 04:37:42PM +0200, Jack Jansen wrote: > > On Tuesday, July 2, 2002, at 03:57 , Oren Tirosh wrote: > >> Uhm... I'm confused: macimport stores a pointe
[翻译]在生产环境中分析 Python 代码性能
python-wikitcms - Python module for interacting with Fedora wiki release validation pages (https://fedoraproject.org/wiki/Wikitcms
# Python Enum and/or named-integer class (Python recipe) by Graham Poulter ActiveState Code (http://code.activestate.com/recipes/577921/) Recipe for Python Enum class that builds on the "FOO = 1" pattern by adding a printable name. In other words, an Enum instance is a named integer. Python, 38 lines Download Copy to clipboard 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 """Enumeration class representing a named integer.""" class Enum(int
A collection of line chart examples made with Python, coming with explanation and reproducible code
Kili Python SDK
The objective of this post is to explain how to create a simple socket server using Python and reach it with a client
## Writing Python iterators in C Posted on Aug 26, 2016 · by Folkert de Vries When I wanted to implement a python iterator from C using the Python C api, there was almost no information on it. At a time when we move to using more languages - to levarage each’s specific strengths - it is crucial to have a clear and approachable interop story for Python. In this article, I implement a custom iterator for Freestyle - a stylized edge render engine that is integrated into Blender . The example should generali