Urgent.News

the world's headlines, one feed

Editions

Tech

Mind-bending self-replicating GIF code prints an exact copy of itself, is both a program and its own visual output — champion coder shows off 'Piet Quine' technique

A champion coder's latest confection is a Piet Quine – a GIF image that prints itself byte-for-byte.

Mind-bending self-replicating GIF code prints an exact copy of itself, is both a program and its own visual output — champion coder shows off 'Piet Quine' technique

Champion programmer Yusuke Endoh has created a fascinating Piet Quine, a GIF that simultaneously acts as the source code and its visual output. This extraordinary feat merges the concepts of Piet, an esoteric programming language that generates colorful, tile-based artwork, and Quine, a program that independently reproduces its own code without external input.

In this unique composition, the GIF undergoes a 'load data' phase, followed by a thorough examination of the GIF file header and palette information. The main challenge lies in the incorporation of binary data, compression, and an intricate flow that must be carefully handled to achieve the desired result. Notably, the source image consists of two distinct parts: a data section compressed via adaptive run-length encoding, and a code segment.

Endoh initially managed to accomplish this creation in 2009, but the resulting GIF was excessively tall, making it unsuitable for visual appreciation. To rectify this issue, Endoh enlisted the assistance of Claude Code, an AI system, to analyze and reconstruct the original script and craft a more compact 'landscape' Piet Quine. After extensive refining and optimization, the final product emerged, neatly fitting into a 4:3 landscape image with dimensions of 252 x 189 pixels.

This remarkable achievement is driven by Endoh's desire to raise awareness of the 2026 Obfuscated Programming Language Design Contest, which is currently ongoing. The contest invites participants to design an esoteric programming language and submit their creations, with Endoh serving as one of the esteemed judges. The submission deadline is October 1, and interested individuals are encouraged to participate in this intriguing challenge.

Written by urgent.news from Tom's Hardware's reporting — not their text. Machine-written — it may contain errors, so check the original before relying on it.

Read the original at tomshardware.com →

More in Tech

Foldable 'iPhone Ultra' Rumored to Come in These Two Colors

Foldable 'iPhone Ultra' Rumored to Come in These Two Colors

New images of camera protector accessories for the " iPhone Ultra " suggest Apple's first foldable iPhone will launch in silver and dark blue finishes. Leaker Sonny Dickson yesterday shared images of two third-party camera protectors designed to fit over the ‌iPhone Ultra‌'s camera bump, with one in silver and one in a dark blue…

Microservices vs Monolith: The Quest for the Holy Grail (Inspired by Monty Python)

The Quest Begins (The "Why") Picture this: I’m sipping coffee, staring at a screen full of latency spikes, and the product manager keeps asking, “Why does our API choke whenever traffic spikes?” We’d…

  • Monolithic application's performance issues compared to Monty Python's King Arthur scene
  • Rate limiter solution explored as in-memory vs microservice implementation
  • Redis-backed token bucket guarantees exact limits, low latency, and operational simplicity

Pulse Width Modulation in ESP32

Note: This post is not completed yet. Introduction ESP32s have a peripheral module called LEDC , which stands for "LED Control" or "LED PWM Controller".

Distributed Storage 101: How It Works and When You Actually Need It

Distributed storage isn't magic — it's a set of trade-offs. Here's how it actually works under the hood. Key Stats Metric Figure Orgs running distributed storage (mid-size+) ~68% Primary driver: HA/failure tolerance 74% Single-node disk failure recovery time 2–8 hours Teams that regretted distributing too early ~23% What Makes Storage…