login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A030157 Even numbers k such that in k^2 the parity of digits alternates. 5
0, 2, 4, 6, 16, 26, 36, 74, 84, 96, 204, 264, 296, 384, 404, 426, 574, 584, 606, 726, 736, 764, 874, 884, 964, 1464, 1584, 1596, 1704, 2036, 2074, 2084, 2184, 2916, 2926, 2964, 3306, 3536, 3764, 3816, 4116, 4264, 4306, 5684, 5726, 5736, 5874 (list; graph; refs; listen; history; text; internal format)
OFFSET
1,2
LINKS
Giovanni Resta, Table of n, a(n) for n = 1..10000 (first 2000 terms from Robert Israel)
MAPLE
alp:= proc(n) local L, d;
L:= convert(n, base, 10);
d:= nops(L);
if d::even then L:= L + map(op, [[0, 1]$(d/2)]) else L:= L + map(op, [[0, 1]$((d-1)/2), [0]]) fi;
nops(convert(L mod 2, set))=1
end proc:
select(t -> alp(t^2), [seq(i, i=0..10000, 2)]); # Robert Israel, Aug 15 2018
MATHEMATICA
id[n_]:=IntegerDigits[n^2]; t={}; Do[If[Length[id[n]]==1, AppendTo[t, n], If[Union[Abs[Differences[Boole/@EvenQ[id[n]]]]]=={1}, AppendTo[t, n]]], {n, 0, 6000, 2}]; t (* Vincenzo Librandi, Aug 15 2018 *)
CROSSREFS
Cf. A030158 (the squares).
Sequence in context: A228119 A078148 A076075 * A162580 A098426 A365639
KEYWORD
nonn,base
AUTHOR
EXTENSIONS
Offset changed by Robert Israel, Aug 15 2018
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 23 03:30 EDT 2024. Contains 371906 sequences. (Running on oeis4.)