Skip to content
The Scroll Art Museum

Diamond Sky

Al Sweigart, 2024. A star- and diamond-filled sky.

This piece is based on Project 16 - Diamonds from Sweigart's The Big Book of Small Python Projects, which creates ASCII art diamonds of various sizes. Sweigart made Diamond Sky before Full of Squares, but the two share similar styles.

This is the first piece where the code has a rows array that contains the next few rows to display. If the program randomly generates a diamond that is 12 rows high, the rows array is expanded to fit the next 12 rows. Sweigart calls this form of scroll art a row buffer. It is a bit more advanced than the wallpaper style of a repeating static pattern, and he finds the effect much more interesting to view.

Python source code

Customize
Settings