%I #27 Nov 26 2023 06:38:20
%S 1,2,2,2,2,4,4,4,3,4,4,7,7,6,5,7,7,7,7,9,11,12,12,12,11,11,10,11,11,
%T 12,12,12,11,12,12,13,13,13,17,18,18,15,15,18,21,17,17,19,19,18,17,16,
%U 16,20,20,23,25,23,23,26,26,24,22,24,24,27,27,27,25,28,28,30,30,32,31,30
%N a(n) is the number of distinct values taken by binomial(n,j) mod j for j in [1..n].
%H Robin Visser, <a href="/A080217/b080217.txt">Table of n, a(n) for n = 1..10000</a> (terms n = 1..1000 from Vincenzo Librandi).
%F a(n) = Card(Union{j=1..n} binomial(n,j) mod j).
%e n=14: {binomial(14,j) mod j, j=1..14} = {0,1,1,1,2,3,2,3,4,1,1,7,1,1} includes six distinct residues (0,1,2,3,4,7) so a(14) = 6.
%t Table[Length[Union[Table[Mod[Binomial[n, j], j], {j, 1, n}]]], {n, 1, 256}]
%o (PARI) a(n) = #vecsort(vector(n, j, binomial(n, j) % j), ,8); \\ _Michel Marcus_, Jul 29 2017
%o (Sage) def a(n):
%o return len(set([binomial(n,j)%j for j in range(1, n+1)])) # _Robin Visser_, Nov 26 2023
%Y Cf. A007318, A080216, A081370, A081371.
%K nonn
%O 1,2
%A _Labos Elemer_, Mar 21 2003