emacs-tangents
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: (*) -> 1


From: Emanuel Berg
Subject: Re: (*) -> 1
Date: Tue, 24 Jan 2023 03:33:56 +0100
User-agent: Gnus/5.13 (Gnus v5.13)

Jean Louis wrote:

> (defun elbf-char (n)
>   (concat "(+ " (string-replace "*" "(*)" (make-string n ?*)) ")"))
>
> (defun elbf-string (string)
>   (let ((list (string-to-list string)))
>     (with-temp-buffer
>       (insert "(string ")
>       (while list
>       (insert (elbf-char (pop list))))
>       (insert ")")
>       (buffer-string))))

Not bad!

Only: Hard coding the same data several times -> court martial.

But it's not like there is real punishment or anything ...

-- 
underground experts united
https://dataswamp.org/~incal




reply via email to

[Prev in Thread] Current Thread [Next in Thread]