Yes, format is faster and also returns NIL if input is not a valid number : (any "9a") -> 9a : (format "9a") -> NIL
PositronPro -------- Original Message -------- On 4 Dec 2018 12:12 pm, Alexander Burger wrote: > On Tue, Dec 04, 2018 at 06:18:13AM +0000, PositronPro wrote: >> Hi, Welcome back! >> >> Did you try (any "9")? >> It will parse & return number from symbol >> Try (help 'any T) > > Yes. Even better - and more efficient - is 'format': > > (format (opt)) > > Examples in the PicoLisp distro are in lib/http.l > > (de -server () > (server (format (opt)) (opt)) ) > > or bin/pilPretty > > (let N 0 > (in NIL > (do (dec (format (opt))) > ... > > ☺/ A!ex > > -- > UNSUBSCRIBE: mailto:[email protected]?subject=Unsubscribe
