Primes whose first and last number is 3: Difference between revisions

Content added Content deleted
(Added Sidef)
m (→‎{{header|Sidef}}: optimization)
Line 448: Line 448:
callback(s.digits2num(base))
callback(s.digits2num(base))
for k in (0 .. base**(upto.len(base) - 2*s.len)) {
for k in (0 .. base**(upto.len(base) - 2*s.len)) {

break if (s + k.digits(base) + s -> digits2num(base) > upto)


Inf.times { |j|
Inf.times { |j|