OFFSET
1,1
EXAMPLE
4 and 5 in base 6 are 4 and 5 and concat(4,5) = 45 in base 10 is 29;
6 and 7 in base 6 are 10 and 11 and concat(10,11) = 1011 in base 10 is 223.
MAPLE
with(numtheory): P:= proc(q, h) local a, b, c, d, k, n; a:=convert(q+1, base, h); b:=convert(q, base, h); c:=[op(a), op(b)]; d:=0; for k from nops(c) by -1 to 1 do d:=h*d+c[k]; od; if isprime(d) then d; fi; end: seq(P(i, 6), i=1..1000);
MATHEMATICA
With[{b = 6}, Select[Map[FromDigits[Flatten@ IntegerDigits[#, b], b] &, Partition[Range@ 360, 2, 1]], PrimeQ]] (* Michael De Vlieger, May 23 2017 *)
CROSSREFS
KEYWORD
nonn,base,easy
AUTHOR
Paolo P. Lava, May 23 2017
STATUS
approved