A forum of ‘code golfers’—programmers who create and solve creative programming puzzles for kicks—are using code to break classic art works down to their base pixels, then rebuild them to look like other classic artworks. The resulting images show us, for example, what Grant Wood’s American Gothic would look like if painted in the bright oranges and blacks Edvard Munch used in The Scream, or what the Mona Lisa would look like if DaVinci had run out of all his paints, save for the colors in Van Gogh’s Starry Night. Take, for example, Mona Lisa morphing into the Wood’s classic.
Videos by VICE
![](https://www.vice.com/wp-content/uploads/sites/2/2024/07/1407346168Mona___AG.gif)
This thread began when CodeGolf user Richard Stauffer, aka Calvin’sHobbies, issued the forum a simple challenge: “You are given two true color images, the Source and the Palette. Your task is to create an algorithm that makes the most accurate looking copy of the Source by only using the pixels in the Palette. Each pixel in the Palette must be used exactly once in a unique position in this copy. The copy must have the same dimensions as the Source.”
Code golfers came out of the woodwork, both to solve the puzzle and to just watch the results, earning Stauffer 34 answers and nearly 36,000 views. To contextualize, the next most-viewed puzzle on the site’s front page has about 7,000 views. The top voted commenter and winner of Stauffer’s code golf puzzle was aditsu, whose algorithm created the cleanest images.
This project inspires some interesting what-ifs about form and color—What if Edvard Munch was really into glitchy rainbows?, for example—but the really compelling aspect is that the code breaks down a few of the most lauded artistic works in human history to their base data points, and reinterprets them into something new(ish) in the blink of an eye. It just goes to show, even in the digital age, great art is worth more than the sum of its pixels.
Check out aditsu’s winning code-powered mix n’ matches below.
Source: Mona Lisa; Palette: Starry Night
Source: The Scream; Palette: Spheres
Source: Spheres; Palette: Mona Lisa
Source: Starry Night; Palette: The Scream
Check out the original thread here to see the complete pixel sorting algorithm, and to look at more pixel-sorted art mashups.
Related:
Use Your Mouse To Push Pixels Like Putty
Here’s What Artificially Intelligent Pixel Bending Looks Like
[Premiere] Dive Into The Clouds In This Code-Generated Music Video