Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
13
Task/Happy-numbers/PicoLisp/happy-numbers.l
Normal file
13
Task/Happy-numbers/PicoLisp/happy-numbers.l
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
(de happy? (N)
|
||||
(let Seen NIL
|
||||
(loop
|
||||
(T (= N 1) T)
|
||||
(T (member N Seen))
|
||||
(setq N
|
||||
(sum '((C) (** (format C) 2))
|
||||
(chop (push 'Seen N)) ) ) ) ) )
|
||||
|
||||
(let H 0
|
||||
(do 8
|
||||
(until (happy? (inc 'H)))
|
||||
(printsp H) ) )
|
||||
Loading…
Add table
Add a link
Reference in a new issue