As this month's LotM (Forth) was not gaining much participation, I guessed it's partly because it's way too low-level, so I was looking into Factor as a modern, high-level alternative to Forth. If it goes well, I'm planning to add a LotM proposal so that other people can look into it.
But I found a major issue in code golf scoring for Factor: most submissions omit the required imports from the byte count. Some of them actually work when tested in the REPL without any setting, but many don't (as the REPL loads only part of the libraries by default). (The existing answers in Factor can be found via this SEDE query.)
They can be made to work if we add a global setting script in
.factor-rc like this:
! .factor-rc USE: parser auto-use ! script.factor 1.2 dup + floor .
script.factor, we need to load
kernel library for
.. Without the
.factor-rc file, we'd need to write this to make it work:
USING: kernel math math.functions prettyprint ; 1.2 dup + floor .
(Note that using the rc-file generates a warning to STDOUT, so it can't be used for a full program.)
Otherwise, if we assume REPL environment, "auto use" is a built-in feature, which (disabled by default) can be enabled via mouse or by typing
parser library is available by default in the REPL.) REPL also starts with "auto use" enabled by default if the same
So the question is: Should I count the content of
.factor-rc file (20B), or
auto-use<ENTER> command in REPL (9B), if I want to use this feature and exclude imports from byte count?
FWIW, an earlier mention of "auto use" can be found in this answer.