%I #10 Oct 26 2016 15:24:24
%S 1,2,3,4,5,6,1,1,2,3,4,5,6,2,1,2,3,4,5,6,3,1,2,3,4,5,6,4,1,2,3,4,5,6,
%T 5,1,2,3,4,5,6,6,1,2,3,4,5,6,1,1,2,3,4,5,6,1,1,2,3,4,5,6,2,1,2,3,4,5,
%U 6,3,1,2,3,4,5,6,4,1,2,3,4,5,6,5,1,2
%N a(n) = n/7^m mod 7, where 7^m is the greatest power of 7 that divides n.
%C a(n) is the rightmost nonzero digit in the base 7 expansion of n.
%H Clark Kimberling, <a href="/A277545/b277545.txt">Table of n, a(n) for n = 1..10000</a>
%F a(n) = A242603(n) mod 7. - _Michel Marcus_, Oct 20 2016
%e a(9) = (9/7 mod 7) = 2.
%t Table[Mod[n/7^IntegerExponent[n, 7], 7], {n, 1, 160}]
%o (PARI) a(n) = n/7^valuation(n, 7) % 7; \\ _Michel Marcus_, Oct 20 2016
%Y Cf. A010876, A242603.
%K nonn,easy
%O 1,2
%A _Clark Kimberling_, Oct 19 2016
|