week 32, 2019

The blue cat with white socks

On our way to the town centre my mother and I encountered a beautiful blue cat with white socks. The cat was very friendly and loved to be petted.

A blue cat with white socks
A beautiful blue cat with white socks

Performance Wiggle Room

“Premature optimization is the root of all evil“: the famous Knuth-ism that we all know and… well, that we all know. It’s hard to go a day of reading programming blogs without someone referencing this and leaving their particular footnote on it. I suppose today I am that someone.

Source Performance Wiggle Room, an article by Doug Thayer.

Six Shades of Coupling

[W]e should pursue loose coupling, so one would be able to easily analyze/debug/maintain any class, without detailed knowledge about other classes within the system. The looser the coupling is, the more independent the classes are.

In the evening I read Six Shades of Coupling, an article by Mr. Picky.

The six types of coupling from those considered as the least to those that are the most welcome are:

  • Content Coupling,
  • Common Coupling,
  • External Coupling,
  • Control Coupling,
  • Stamp Coupling, and Data Coupling

A recommended read.

Twenty Lego Scorpions Arrived

In the afternoon, the twenty new black Lego scorpions, part number 30169, I had ordered the 30th of July arrived.

Twenty black Lego scorpions
Twenty black Lego scorpions, part number 30169.

I had placed the order with Vintage Sets & Bits in the UK via the BrickLink website.

I am very happy with those tiny arachnids, and I am sure our children will play a lot with them.

Memory management in Python

Everything in Python is an object. Some objects can hold other objects, such as lists, tuples, dicts, classes, etc. Because of dynamic Python's nature, such approach requires a lot of small memory allocations. To speed-up memory operations and reduce fragmentation Python uses a special manager on top of the general-purpose allocator, called PyMalloc.

In the evening I read Memory management in Python, a quick overview by Artem Golubin.