HackerReposA FIELD GUIDE TO OPEN SOURCE
ProSponsor the shelf♧ 0
← Back to top all-time
susam
cfrs
HTML2023–2024
susam / cfrs

cfrs

An extremely minimal drawing language consisting of only 6 simple commands: C, F, R, S, [, and ].

2Distinct people
11Mentions
0Explicit recommenders
261GitHub stars
REPOSITORY AT A GLANCE

What to know before exploring

What it is

An extremely minimal drawing language consisting of only 6 simple commands: C, F, R, S, [, and ].

GitHub

Where it is used

No documented product use has been verified yet.

What people are saying

No recommendation phrase was found in the indexed comments.

No classified warning is attached to this page. Read the discussions before treating silence as approval.

Also in these discussions

No other repository is repeatedly linked in the same discussions.

This week on Hacker News

Nov 7–Nov 14 UTC · Direct repository links and separately labeled related project stories. Indexed through 11/14/2026, 3:56:07 PM UTC.

No direct repository links were found in the indexed HN discussions over the past seven days. Older discussions are available below.

Mentions over time

HN mentions by month11 dated mentions

Observed mentions: 2023-10-18 22:29:16 UTC to 2024-08-23 07:41:20 UTC.

02462023-10-01 00:00:00 UTC to 2023-11-01 00:00:00 UTC (exclusive): 6 mentions; 3 submissions, 3 commentsOct 20232023-11-01 00:00:00 UTC to 2023-12-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2023-12-01 00:00:00 UTC to 2024-01-01 00:00:00 UTC (exclusive): 1 mentions; 1 submissions, 0 comments2024-01-01 00:00:00 UTC to 2024-02-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2024-02-01 00:00:00 UTC to 2024-03-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2024-03-01 00:00:00 UTC to 2024-04-01 00:00:00 UTC (exclusive): 1 mentions; 1 submissions, 0 commentsMar 20242024-04-01 00:00:00 UTC to 2024-05-01 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 comments2024-05-01 00:00:00 UTC to 2024-06-01 00:00:00 UTC (exclusive): 1 mentions; 1 submissions, 0 comments2024-06-01 00:00:00 UTC to 2024-07-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2024-07-01 00:00:00 UTC to 2024-08-01 00:00:00 UTC (exclusive): 0 mentions; 0 submissions, 0 comments2024-08-01 00:00:00 UTC to 2024-09-01 00:00:00 UTC (exclusive): 1 mentions; 1 submissions, 0 commentsAug 2024

Counts come from the repository’s dated source evidence. Index cutoff: 2026-11-02 08:16:59 UTC.

View mention counts and date ranges
UTC ranges include their start and exclude their end. Select a period to filter the source evidence.
PeriodStart (UTC)End (exclusive, UTC)MentionsSubmissionsComments
Oct 20232023-10-01 00:00:00 UTC2023-11-01 00:00:00 UTC633
Nov 20232023-11-01 00:00:00 UTC2023-12-01 00:00:00 UTC000
Dec 20232023-12-01 00:00:00 UTC2024-01-01 00:00:00 UTC110
Jan 20242024-01-01 00:00:00 UTC2024-02-01 00:00:00 UTC000
Feb 20242024-02-01 00:00:00 UTC2024-03-01 00:00:00 UTC000
Mar 20242024-03-01 00:00:00 UTC2024-04-01 00:00:00 UTC110
Apr 20242024-04-01 00:00:00 UTC2024-05-01 00:00:00 UTC101
May 20242024-05-01 00:00:00 UTC2024-06-01 00:00:00 UTC110
Jun 20242024-06-01 00:00:00 UTC2024-07-01 00:00:00 UTC000
Jul 20242024-07-01 00:00:00 UTC2024-08-01 00:00:00 UTC000
Aug 20242024-08-01 00:00:00 UTC2024-09-01 00:00:00 UTC110

What Hacker News says

11 sources
Thanks! Glad you like it. The sibling comment by majewsky is spot on. There is not much parsing going on. Every character is read one at a time and the turtle's state is changed. Indeed the "[" and "]" commands are implemented with a stack. The entire implementation is a single HTML page written in plain HTML + JavaScript. The evaluation of the code happens here: <https://github.com/susam/cfr/blob/0.2.0/cfr.html#L204>.
In Show HN: CFR[]: Very minimal drawing language with 5 commands: C, F, R, [, ]
> The syntax definitions on github are ... Are you referring to the short list at the top of the README on GitHub? That list does not provide "syntax definitions". That's just a quick introduction about what is about to come. The commands are explained in detail in the section "Commands" later here: https://github.com/susam/cfr#commands > F (fill/forward): draw a pixel and move forward The command "F" does not draw a pixel and move forward. Instead "F" moves forward first and then draws a cell. > [ ... ] (loop): anything inside this is executed twice The control flow command "[" can be written without a corresponding "]". For example "[", "[F", "[[F", etc. are valid CFR[] inputs. Again, the section of the README I have linked to above defines what "[" and what "]" are.
In Show HN: CFR[]: Very minimal drawing language with 5 commands: C, F, R, [, ]
This is very timely because I completed writing a useless software just a few minutes ago: CFR Brackets: https://susam.net/cfr.html Demo: https://susam.net/cfr.html#3 Source: https://github.com/susam/cfr It is a very minimal drawing language that supports only 5 commands: C (change colour), F (move forward), R (rotate), [ (begin block), and ] (repeat block). The commands are slightly inspired by the Logo programming language. The minimal nature is inspired by P′′. However, unlike both, this is not Turing complete. No practical usage is intended. I wrote it for fun and I am hoping to have some more fun with it trying to draw interesting shapes using it while keeping the input code as small as possible. “I think that it's extraordinarily important that we in computer science keep fun in computing.” -- Alan J. Perlis
In Write more "useless" software

MAKE YOURSELF AT HOME

A few shortcuts

/
Search the collection
?
Open this guide
Esc
Close dialogs and navigation

Your saved repositories and interests stay in this browser.