cp's OEIS Frontend

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.

A071648 Sum of even decimal digits of n.

This page as a plain text file.
%I A071648 #15 Dec 19 2018 14:44:14
%S A071648 0,2,0,4,0,6,0,8,0,0,0,2,0,4,0,6,0,8,0,2,2,4,2,6,2,8,2,10,2,0,0,2,0,4,
%T A071648 0,6,0,8,0,4,4,6,4,8,4,10,4,12,4,0,0,2,0,4,0,6,0,8,0,6,6,8,6,10,6,12,
%U A071648 6,14,6,0,0,2,0,4,0,6,0,8,0,8,8,10,8,12,8,14,8,16,8,0,0,2
%N A071648 Sum of even decimal digits of n.
%H A071648 Michael De Vlieger, <a href="/A071648/b071648.txt">Table of n, a(n) for n = 1..10000</a>
%F A071648 a(n) = A007953(n) - A071649(n). (Corrected by _M. F. Hasler_, Dec 09 2018)
%t A071648 Array[Total@ Select[IntegerDigits@ #, EvenQ] &, 101] (* _Michael De Vlieger_, Dec 09 2018 *)
%o A071648 (PARI) a(n)=my(d=digits(n)); sum(i=1,#d,if(d[i]%2,,d[i])) \\ _Charles R Greathouse IV_, Apr 04 2014
%o A071648 (PARI) A071648(n)=vecsum(select(d->!bittest(d,0),digits(n))) \\ Nearly twice as fast. - _M. F. Hasler_, Dec 09 2018
%Y A071648 Cf. A007953, A071649, A071650.
%K A071648 nonn,base,easy
%O A071648 1,2
%A A071648 _Reinhard Zumkeller_, May 28 2002