Sujet : Re: Add the numbers in a 9x9 multiplication Table
De : Nobody447095 (at) *nospam* here-nor-there.org (B. Pym)
Groupes : rec.puzzles comp.lang.lisp comp.lang.pythonDate : 06. Jun 2025, 16:25:51
Autres entêtes
Organisation : A noiseless patient Spider
Message-ID : <101v19u$2bho4$1@dont-email.me>
References : 1 2 3
User-Agent : XanaNews/1.18.1.6
B. Pym wrote:
Kaz Kylheku wrote:
1> (sum-each ((i 1..10) (j 1..10)) (* i j))
285
2> (sum-each-prod ((i 1..10) (j 1..10)) (* i j))
2025
Gauche Scheme
(use srfi-42)
(sum-ec (: i 10) (: j 10) (* i j))
===>
2025
Equivalent but more prolix:
(sum-ec (:range i 0 10) (:range j 0 10) (* i j))