\L
, \U
, \E
for fractals in GNU sed
The case switching special sequences help in "toggling" a line. An example is the following challenge to produce a fractal X on anagol, whose shortest sed solution by mitchs et al is reproduced here.
s/^/X\n/
:
s/^.\{,27\}\n/&\L&\U&/mg
//s/[ X]/& &/g
s/x/ X /g
t
If the fractal uses another character to fill it, then at the end you can add a transliterate.