Jump to content

Ludic numbers: Difference between revisions

m
→‎{{header|Sidef}}: modified the code to work with Sidef 2.30
(Replaced PowerShell with simpler example)
m (→‎{{header|Sidef}}: modified the code to work with Sidef 2.30)
Line 2,480:
Enumerator({ |collect|
collect(1)
var arr = @(2..nmax)
while (arr) {
collect(var n = arr[0])
Line 2,498:
 
var a = ludics_upto(250).to_a
say("Ludic triples below 250: ", a.grep{|x| a.contains_all([x+2, x+6]) } \
.map {|x| '(' + [x, x+2, x+6].join(' ') + ')' } \
.join(' '))</lang>
{{out}}
2,747

edits

Cookies help us deliver our services. By using our services, you agree to our use of cookies.