This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A065852 #20 Jun 24 2024 15:31:40 %S A065852 1,2,3,4,4,5,3,5,4,6,4,6,4,5,5,5,4,6,5,6,5,6,5,6,5,6,5,6,5,6,5,6,6,6, %T A065852 6,6,5,6,6,6,5,6,6,6,6,5,5,6,6,6,6,6,5,6,6,6,5,6,6,6,6,6,6,6,6,6,5,6, %U A065852 6,6,5,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6,6 %N A065852 Let u be any string of 3 digits from {0,...,n-1}; let f(u) = number of distinct primes, not beginning with 0, formed by permuting the digits of u to a base-n number; then a(n) = max_u f(u). %C A065852 a(n) = 6 for 73 <= n < 985, except a(192) = 5. %e A065852 a(2)=1 because 101 is prime and there are no two 3-digit primes with the same number of ones in base two. %t A065852 c[x_, n_] := %t A065852 Module[{}, %t A065852 Length[Select[Permutations[x], %t A065852 First[#] != 0 && PrimeQ[FromDigits[#, n]] &]]]; %t A065852 A065852[n_] := Module[{i}, %t A065852 Return[ Max[Map[c[#, n] &, DeleteDuplicatesBy[Tuples[Range[0, n - 1], 3], Table[Count[#, i], {i, 0, n - 1}] &]]]]]; %t A065852 Table[A065852[n], {n, 2, 30}] (* _Robert Price_, Mar 30 2019 *) %Y A065852 Cf. A065843, A065844, A065845, A065846, A065847, A065848, A065849, A065850, A065851, A065853. %K A065852 base,nonn %O A065852 2,2 %A A065852 _Sascha Kurz_, Nov 24 2001 %E A065852 Definition corrected by _David A. Corneth_, Apr 23 2016